clox 0.9__tar.gz → 1.0__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Potentially problematic release.
This version of clox might be problematic. Click here for more details.
- {clox-0.9 → clox-1.0}/CHANGELOG.md +8 -1
- {clox-0.9 → clox-1.0}/PKG-INFO +13 -6
- {clox-0.9 → clox-1.0}/README.md +2 -2
- {clox-0.9 → clox-1.0}/SECURITY.md +2 -2
- {clox-0.9 → clox-1.0}/clox/functions.py +20 -14
- {clox-0.9 → clox-1.0}/clox/params.py +2 -2
- {clox-0.9 → clox-1.0}/clox.egg-info/PKG-INFO +13 -6
- {clox-0.9 → clox-1.0}/dev-requirements.txt +1 -1
- {clox-0.9 → clox-1.0}/setup.py +3 -3
- {clox-0.9 → clox-1.0}/AUTHORS.md +0 -0
- {clox-0.9 → clox-1.0}/COUNTRIES.md +0 -0
- {clox-0.9 → clox-1.0}/FACES.md +0 -0
- {clox-0.9 → clox-1.0}/LICENSE +0 -0
- {clox-0.9 → clox-1.0}/MANIFEST.in +0 -0
- {clox-0.9 → clox-1.0}/TIMEZONES.md +0 -0
- {clox-0.9 → clox-1.0}/clox/__init__.py +0 -0
- {clox-0.9 → clox-1.0}/clox/__main__.py +0 -0
- {clox-0.9 → clox-1.0}/clox/jcalendar.py +0 -0
- {clox-0.9 → clox-1.0}/clox.egg-info/SOURCES.txt +0 -0
- {clox-0.9 → clox-1.0}/clox.egg-info/dependency_links.txt +0 -0
- {clox-0.9 → clox-1.0}/clox.egg-info/entry_points.txt +0 -0
- {clox-0.9 → clox-1.0}/clox.egg-info/requires.txt +0 -0
- {clox-0.9 → clox-1.0}/clox.egg-info/top_level.txt +0 -0
- {clox-0.9 → clox-1.0}/requirements.txt +0 -0
- {clox-0.9 → clox-1.0}/setup.cfg +0 -0
|
@@ -5,6 +5,12 @@ The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/)
|
|
|
5
5
|
and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.html).
|
|
6
6
|
|
|
7
7
|
## [Unreleased]
|
|
8
|
+
## [1.0] - 2025-05-06
|
|
9
|
+
### Added
|
|
10
|
+
- Local time
|
|
11
|
+
### Changed
|
|
12
|
+
- `clox_info` function modified
|
|
13
|
+
- `run_clock` function modified
|
|
8
14
|
## [0.9] - 2025-04-14
|
|
9
15
|
### Added
|
|
10
16
|
- Timezone difference
|
|
@@ -65,7 +71,8 @@ and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.
|
|
|
65
71
|
- `TIMEZONES.md`
|
|
66
72
|
- `FACES.md`
|
|
67
73
|
|
|
68
|
-
[Unreleased]: https://github.com/sepandhaghighi/clox/compare/
|
|
74
|
+
[Unreleased]: https://github.com/sepandhaghighi/clox/compare/v1.0...dev
|
|
75
|
+
[1.0]: https://github.com/sepandhaghighi/clox/compare/v0.9...v1.0
|
|
69
76
|
[0.9]: https://github.com/sepandhaghighi/clox/compare/v0.8...v0.9
|
|
70
77
|
[0.8]: https://github.com/sepandhaghighi/clox/compare/v0.7...v0.8
|
|
71
78
|
[0.7]: https://github.com/sepandhaghighi/clox/compare/v0.6...v0.7
|
{clox-0.9 → clox-1.0}/PKG-INFO
RENAMED
|
@@ -1,15 +1,15 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: clox
|
|
3
|
-
Version: 0
|
|
3
|
+
Version: 1.0
|
|
4
4
|
Summary: A Geeky Clock for Terminal Enthusiasts
|
|
5
5
|
Home-page: https://github.com/sepandhaghighi/clox
|
|
6
|
-
Download-URL: https://github.com/sepandhaghighi/clox/tarball/
|
|
6
|
+
Download-URL: https://github.com/sepandhaghighi/clox/tarball/v1.0
|
|
7
7
|
Author: Sepand Haghighi
|
|
8
8
|
Author-email: me@sepand.tech
|
|
9
9
|
License: MIT
|
|
10
10
|
Project-URL: Source, https://github.com/sepandhaghighi/clox
|
|
11
11
|
Keywords: clock time timer timezone terminal cli geek clox
|
|
12
|
-
Classifier: Development Status ::
|
|
12
|
+
Classifier: Development Status :: 5 - Production/Stable
|
|
13
13
|
Classifier: Natural Language :: English
|
|
14
14
|
Classifier: License :: OSI Approved :: MIT License
|
|
15
15
|
Classifier: Operating System :: OS Independent
|
|
@@ -104,13 +104,13 @@ Clox is a terminal-based clock application designed for terminal enthusiasts who
|
|
|
104
104
|
## Installation
|
|
105
105
|
|
|
106
106
|
### Source Code
|
|
107
|
-
- Download [Version 0
|
|
107
|
+
- Download [Version 1.0](https://github.com/sepandhaghighi/clox/archive/v1.0.zip) or [Latest Source](https://github.com/sepandhaghighi/clox/archive/dev.zip)
|
|
108
108
|
- `pip install .`
|
|
109
109
|
|
|
110
110
|
### PyPI
|
|
111
111
|
|
|
112
112
|
- Check [Python Packaging User Guide](https://packaging.python.org/installing/)
|
|
113
|
-
- `pip install clox==0
|
|
113
|
+
- `pip install clox==1.0`
|
|
114
114
|
|
|
115
115
|
|
|
116
116
|
## Usage
|
|
@@ -292,6 +292,12 @@ The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/)
|
|
|
292
292
|
and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.html).
|
|
293
293
|
|
|
294
294
|
## [Unreleased]
|
|
295
|
+
## [1.0] - 2025-05-06
|
|
296
|
+
### Added
|
|
297
|
+
- Local time
|
|
298
|
+
### Changed
|
|
299
|
+
- `clox_info` function modified
|
|
300
|
+
- `run_clock` function modified
|
|
295
301
|
## [0.9] - 2025-04-14
|
|
296
302
|
### Added
|
|
297
303
|
- Timezone difference
|
|
@@ -352,7 +358,8 @@ and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.
|
|
|
352
358
|
- `TIMEZONES.md`
|
|
353
359
|
- `FACES.md`
|
|
354
360
|
|
|
355
|
-
[Unreleased]: https://github.com/sepandhaghighi/clox/compare/
|
|
361
|
+
[Unreleased]: https://github.com/sepandhaghighi/clox/compare/v1.0...dev
|
|
362
|
+
[1.0]: https://github.com/sepandhaghighi/clox/compare/v0.9...v1.0
|
|
356
363
|
[0.9]: https://github.com/sepandhaghighi/clox/compare/v0.8...v0.9
|
|
357
364
|
[0.8]: https://github.com/sepandhaghighi/clox/compare/v0.7...v0.8
|
|
358
365
|
[0.7]: https://github.com/sepandhaghighi/clox/compare/v0.6...v0.7
|
{clox-0.9 → clox-1.0}/README.md
RENAMED
|
@@ -53,13 +53,13 @@ Clox is a terminal-based clock application designed for terminal enthusiasts who
|
|
|
53
53
|
## Installation
|
|
54
54
|
|
|
55
55
|
### Source Code
|
|
56
|
-
- Download [Version 0
|
|
56
|
+
- Download [Version 1.0](https://github.com/sepandhaghighi/clox/archive/v1.0.zip) or [Latest Source](https://github.com/sepandhaghighi/clox/archive/dev.zip)
|
|
57
57
|
- `pip install .`
|
|
58
58
|
|
|
59
59
|
### PyPI
|
|
60
60
|
|
|
61
61
|
- Check [Python Packaging User Guide](https://packaging.python.org/installing/)
|
|
62
|
-
- `pip install clox==0
|
|
62
|
+
- `pip install clox==1.0`
|
|
63
63
|
|
|
64
64
|
|
|
65
65
|
## Usage
|
|
@@ -28,7 +28,7 @@ def clox_info() -> None:
|
|
|
28
28
|
tprint("Clox")
|
|
29
29
|
tprint("V:" + CLOX_VERSION)
|
|
30
30
|
print(CLOX_OVERVIEW)
|
|
31
|
-
print(CLOX_REPO)
|
|
31
|
+
print("Repo : " + CLOX_REPO)
|
|
32
32
|
|
|
33
33
|
|
|
34
34
|
def clear_screen() -> None:
|
|
@@ -58,9 +58,9 @@ def get_timezone_difference(timezone: str) -> str:
|
|
|
58
58
|
"""
|
|
59
59
|
direction = "ahead"
|
|
60
60
|
tz = pytz.timezone(timezone)
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
difference =
|
|
61
|
+
datetime_timezone = datetime.datetime.now(tz=tz)
|
|
62
|
+
datetime_local = datetime.datetime.now()
|
|
63
|
+
difference = datetime_timezone - tz.localize(datetime_local)
|
|
64
64
|
total_minutes = difference.total_seconds() // 60
|
|
65
65
|
if total_minutes < 0:
|
|
66
66
|
direction = "behind"
|
|
@@ -158,16 +158,16 @@ def print_calendar(
|
|
|
158
158
|
tz = pytz.timezone(timezone)
|
|
159
159
|
v_shift = max(0, v_shift)
|
|
160
160
|
h_shift = max(0, h_shift)
|
|
161
|
-
|
|
162
|
-
|
|
161
|
+
datetime_timezone = datetime_lib.datetime.now(tz=tz)
|
|
162
|
+
date_timezone_str = datetime_timezone.strftime(DATE_FORMAT)
|
|
163
163
|
print('\n' * v_shift, end='')
|
|
164
164
|
print(" " * h_shift, end='')
|
|
165
|
-
print("Today: {date}".format(date=
|
|
165
|
+
print("Today: {date}".format(date=date_timezone_str))
|
|
166
166
|
print(" " * h_shift, end='')
|
|
167
167
|
print("Timezone: {timezone}\n".format(timezone=timezone_str))
|
|
168
|
-
calendar_str = calendar_obj.formatmonth(
|
|
168
|
+
calendar_str = calendar_obj.formatmonth(datetime_timezone.year, datetime_timezone.month)
|
|
169
169
|
if mode == "year":
|
|
170
|
-
calendar_str = calendar_obj.formatyear(
|
|
170
|
+
calendar_str = calendar_obj.formatyear(datetime_timezone.year)
|
|
171
171
|
print("\n".join([" " * h_shift + x for x in calendar_str.split("\n")]))
|
|
172
172
|
|
|
173
173
|
|
|
@@ -203,6 +203,7 @@ def run_clock(
|
|
|
203
203
|
datetime_lib = jdatetime
|
|
204
204
|
format_index = 0
|
|
205
205
|
time_formats = HORIZONTAL_TIME_12H_FORMATS if am_pm else HORIZONTAL_TIME_24H_FORMATS
|
|
206
|
+
time_formats_local = HORIZONTAL_TIME_12H_FORMATS if am_pm else HORIZONTAL_TIME_24H_FORMATS
|
|
206
207
|
if vertical:
|
|
207
208
|
time_formats = VERTICAL_TIME_12H_FORMATS if am_pm else VERTICAL_TIME_24H_FORMATS
|
|
208
209
|
tz = None
|
|
@@ -221,16 +222,21 @@ def run_clock(
|
|
|
221
222
|
clear_screen()
|
|
222
223
|
print('\n' * v_shift, end='')
|
|
223
224
|
print(" " * h_shift, end='')
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
tprint(
|
|
225
|
+
datetime_timezone = datetime_lib.datetime.now(tz=tz)
|
|
226
|
+
time_timezone_str = datetime_timezone.strftime(time_formats[format_index])
|
|
227
|
+
date_timezone_str = datetime_timezone.strftime(DATE_FORMAT)
|
|
228
|
+
tprint(time_timezone_str, font=face, sep="\n" + " " * h_shift)
|
|
228
229
|
if not hide_date:
|
|
229
230
|
print(" " * h_shift, end='')
|
|
230
|
-
print(
|
|
231
|
+
print(date_timezone_str)
|
|
231
232
|
if not hide_timezone:
|
|
232
233
|
print(" " * h_shift, end='')
|
|
233
234
|
print("Timezone: {timezone}".format(timezone=timezone_str))
|
|
235
|
+
if timezone is not None:
|
|
236
|
+
datetime_local = datetime.datetime.now()
|
|
237
|
+
time_local_str = datetime_local.strftime(time_formats_local[format_index])
|
|
238
|
+
print(" " * h_shift, end='')
|
|
239
|
+
print("Local Time: {local_time}".format(local_time=time_local_str))
|
|
234
240
|
time.sleep(1)
|
|
235
241
|
if not no_blink:
|
|
236
242
|
format_index = int(not format_index)
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
"""clox params."""
|
|
3
3
|
import pytz
|
|
4
4
|
|
|
5
|
-
CLOX_VERSION = "0
|
|
5
|
+
CLOX_VERSION = "1.0"
|
|
6
6
|
|
|
7
7
|
CLOX_OVERVIEW = '''
|
|
8
8
|
Clox is a terminal-based clock application designed for terminal enthusiasts who appreciate simplicity,
|
|
@@ -10,7 +10,7 @@ elegance, and productivity within their command-line environment. Whether you're
|
|
|
10
10
|
or simply enjoying the terminal aesthetic, Clox brings a stylish and customizable time display to your workspace.
|
|
11
11
|
'''
|
|
12
12
|
|
|
13
|
-
CLOX_REPO = "
|
|
13
|
+
CLOX_REPO = "https://github.com/sepandhaghighi/clox"
|
|
14
14
|
|
|
15
15
|
ADDITIONAL_INFO = "Additional information: Press `Ctrl+C` to exit."
|
|
16
16
|
EXIT_MESSAGE = "See you. Bye!"
|
|
@@ -1,15 +1,15 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: clox
|
|
3
|
-
Version: 0
|
|
3
|
+
Version: 1.0
|
|
4
4
|
Summary: A Geeky Clock for Terminal Enthusiasts
|
|
5
5
|
Home-page: https://github.com/sepandhaghighi/clox
|
|
6
|
-
Download-URL: https://github.com/sepandhaghighi/clox/tarball/
|
|
6
|
+
Download-URL: https://github.com/sepandhaghighi/clox/tarball/v1.0
|
|
7
7
|
Author: Sepand Haghighi
|
|
8
8
|
Author-email: me@sepand.tech
|
|
9
9
|
License: MIT
|
|
10
10
|
Project-URL: Source, https://github.com/sepandhaghighi/clox
|
|
11
11
|
Keywords: clock time timer timezone terminal cli geek clox
|
|
12
|
-
Classifier: Development Status ::
|
|
12
|
+
Classifier: Development Status :: 5 - Production/Stable
|
|
13
13
|
Classifier: Natural Language :: English
|
|
14
14
|
Classifier: License :: OSI Approved :: MIT License
|
|
15
15
|
Classifier: Operating System :: OS Independent
|
|
@@ -104,13 +104,13 @@ Clox is a terminal-based clock application designed for terminal enthusiasts who
|
|
|
104
104
|
## Installation
|
|
105
105
|
|
|
106
106
|
### Source Code
|
|
107
|
-
- Download [Version 0
|
|
107
|
+
- Download [Version 1.0](https://github.com/sepandhaghighi/clox/archive/v1.0.zip) or [Latest Source](https://github.com/sepandhaghighi/clox/archive/dev.zip)
|
|
108
108
|
- `pip install .`
|
|
109
109
|
|
|
110
110
|
### PyPI
|
|
111
111
|
|
|
112
112
|
- Check [Python Packaging User Guide](https://packaging.python.org/installing/)
|
|
113
|
-
- `pip install clox==0
|
|
113
|
+
- `pip install clox==1.0`
|
|
114
114
|
|
|
115
115
|
|
|
116
116
|
## Usage
|
|
@@ -292,6 +292,12 @@ The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/)
|
|
|
292
292
|
and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.html).
|
|
293
293
|
|
|
294
294
|
## [Unreleased]
|
|
295
|
+
## [1.0] - 2025-05-06
|
|
296
|
+
### Added
|
|
297
|
+
- Local time
|
|
298
|
+
### Changed
|
|
299
|
+
- `clox_info` function modified
|
|
300
|
+
- `run_clock` function modified
|
|
295
301
|
## [0.9] - 2025-04-14
|
|
296
302
|
### Added
|
|
297
303
|
- Timezone difference
|
|
@@ -352,7 +358,8 @@ and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.
|
|
|
352
358
|
- `TIMEZONES.md`
|
|
353
359
|
- `FACES.md`
|
|
354
360
|
|
|
355
|
-
[Unreleased]: https://github.com/sepandhaghighi/clox/compare/
|
|
361
|
+
[Unreleased]: https://github.com/sepandhaghighi/clox/compare/v1.0...dev
|
|
362
|
+
[1.0]: https://github.com/sepandhaghighi/clox/compare/v0.9...v1.0
|
|
356
363
|
[0.9]: https://github.com/sepandhaghighi/clox/compare/v0.8...v0.9
|
|
357
364
|
[0.8]: https://github.com/sepandhaghighi/clox/compare/v0.7...v0.8
|
|
358
365
|
[0.7]: https://github.com/sepandhaghighi/clox/compare/v0.6...v0.7
|
{clox-0.9 → clox-1.0}/setup.py
RENAMED
|
@@ -30,7 +30,7 @@ def read_description() -> str:
|
|
|
30
30
|
setup(
|
|
31
31
|
name='clox',
|
|
32
32
|
packages=['clox'],
|
|
33
|
-
version='0
|
|
33
|
+
version='1.0',
|
|
34
34
|
description='A Geeky Clock for Terminal Enthusiasts',
|
|
35
35
|
long_description=read_description(),
|
|
36
36
|
long_description_content_type='text/markdown',
|
|
@@ -38,7 +38,7 @@ setup(
|
|
|
38
38
|
author='Sepand Haghighi',
|
|
39
39
|
author_email='me@sepand.tech',
|
|
40
40
|
url='https://github.com/sepandhaghighi/clox',
|
|
41
|
-
download_url='https://github.com/sepandhaghighi/clox/tarball/
|
|
41
|
+
download_url='https://github.com/sepandhaghighi/clox/tarball/v1.0',
|
|
42
42
|
keywords="clock time timer timezone terminal cli geek clox",
|
|
43
43
|
project_urls={
|
|
44
44
|
'Source': 'https://github.com/sepandhaghighi/clox'
|
|
@@ -46,7 +46,7 @@ setup(
|
|
|
46
46
|
install_requires=get_requires(),
|
|
47
47
|
python_requires='>=3.7',
|
|
48
48
|
classifiers=[
|
|
49
|
-
'Development Status ::
|
|
49
|
+
'Development Status :: 5 - Production/Stable',
|
|
50
50
|
'Natural Language :: English',
|
|
51
51
|
'License :: OSI Approved :: MIT License',
|
|
52
52
|
'Operating System :: OS Independent',
|
{clox-0.9 → clox-1.0}/AUTHORS.md
RENAMED
|
File without changes
|
|
File without changes
|
{clox-0.9 → clox-1.0}/FACES.md
RENAMED
|
File without changes
|
{clox-0.9 → clox-1.0}/LICENSE
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{clox-0.9 → clox-1.0}/setup.cfg
RENAMED
|
File without changes
|