From 2e4e7ccc5737c10809d202f16164ed2b32771fbd Mon Sep 17 00:00:00 2001 From: Sven Heidemann Date: Wed, 19 Jan 2022 15:06:26 +0100 Subject: [PATCH] Fixed minor issues with console & updated packages --- src/cpl_cli/__init__.py | 4 +-- src/cpl_cli/_templates/__init__.py | 4 +-- src/cpl_cli/_templates/build/__init__.py | 4 +-- src/cpl_cli/_templates/generate/__init__.py | 4 +-- src/cpl_cli/_templates/new/__init__.py | 4 +-- .../_templates/new/console/__init__.py | 4 +-- .../_templates/new/console/source/__init__.py | 4 +-- .../new/console/source/name/__init__.py | 4 +-- .../new/console/source/tests/__init__.py | 4 +-- .../_templates/new/library/__init__.py | 4 +-- .../_templates/new/library/source/__init__.py | 4 +-- .../new/library/source/name/__init__.py | 4 +-- .../new/library/source/tests/__init__.py | 4 +-- src/cpl_cli/_templates/publish/__init__.py | 4 +-- src/cpl_cli/command/__init__.py | 4 +-- src/cpl_cli/configuration/__init__.py | 4 +-- src/cpl_cli/cpl_cli.json | 2 +- src/cpl_cli/live_server/__init__.py | 4 +-- src/cpl_cli/publish/__init__.py | 4 +-- src/cpl_cli/source_creator/__init__.py | 4 +-- src/cpl_core/console/console.py | 3 +- src/cpl_core/cpl_core.json | 8 ++--- src/tests/custom/console/main.py | 33 +++++++++---------- 23 files changed, 61 insertions(+), 61 deletions(-) diff --git a/src/cpl_cli/__init__.py b/src/cpl_cli/__init__.py index ea160497..9b8809b3 100644 --- a/src/cpl_cli/__init__.py +++ b/src/cpl_cli/__init__.py @@ -15,7 +15,7 @@ __title__ = 'cpl_cli' __author__ = 'Sven Heidemann' __license__ = 'MIT' __copyright__ = 'Copyright (c) 2020 - 2021 sh-edraft.de' -__version__ = '2021.11.0.post3' +__version__ = '2021.11.0.post4' from collections import namedtuple @@ -29,4 +29,4 @@ from .main import main from .startup import Startup VersionInfo = namedtuple('VersionInfo', 'major minor micro') -version_info = VersionInfo(major='2021', minor='11', micro='0.post3') +version_info = VersionInfo(major='2021', minor='11', micro='0.post4') diff --git a/src/cpl_cli/_templates/__init__.py b/src/cpl_cli/_templates/__init__.py index 09a7fa07..96db6a05 100644 --- a/src/cpl_cli/_templates/__init__.py +++ b/src/cpl_cli/_templates/__init__.py @@ -15,11 +15,11 @@ __title__ = 'cpl_cli._templates' __author__ = 'Sven Heidemann' __license__ = 'MIT' __copyright__ = 'Copyright (c) 2020 - 2021 sh-edraft.de' -__version__ = '2021.11.0.post3' +__version__ = '2021.11.0.post4' from collections import namedtuple # imports: VersionInfo = namedtuple('VersionInfo', 'major minor micro') -version_info = VersionInfo(major='2021', minor='11', micro='0.post3') +version_info = VersionInfo(major='2021', minor='11', micro='0.post4') diff --git a/src/cpl_cli/_templates/build/__init__.py b/src/cpl_cli/_templates/build/__init__.py index 7ca48186..a94d5b2f 100644 --- a/src/cpl_cli/_templates/build/__init__.py +++ b/src/cpl_cli/_templates/build/__init__.py @@ -15,11 +15,11 @@ __title__ = 'cpl_cli._templates.build' __author__ = 'Sven Heidemann' __license__ = 'MIT' __copyright__ = 'Copyright (c) 2020 - 2021 sh-edraft.de' -__version__ = '2021.11.0.post3' +__version__ = '2021.11.0.post4' from collections import namedtuple # imports: VersionInfo = namedtuple('VersionInfo', 'major minor micro') -version_info = VersionInfo(major='2021', minor='11', micro='0.post3') +version_info = VersionInfo(major='2021', minor='11', micro='0.post4') diff --git a/src/cpl_cli/_templates/generate/__init__.py b/src/cpl_cli/_templates/generate/__init__.py index 1ebb7357..753484a5 100644 --- a/src/cpl_cli/_templates/generate/__init__.py +++ b/src/cpl_cli/_templates/generate/__init__.py @@ -15,11 +15,11 @@ __title__ = 'cpl_cli._templates.generate' __author__ = 'Sven Heidemann' __license__ = 'MIT' __copyright__ = 'Copyright (c) 2020 - 2021 sh-edraft.de' -__version__ = '2021.11.0.post3' +__version__ = '2021.11.0.post4' from collections import namedtuple # imports: VersionInfo = namedtuple('VersionInfo', 'major minor micro') -version_info = VersionInfo(major='2021', minor='11', micro='0.post3') +version_info = VersionInfo(major='2021', minor='11', micro='0.post4') diff --git a/src/cpl_cli/_templates/new/__init__.py b/src/cpl_cli/_templates/new/__init__.py index 98dba467..fd0cb6a2 100644 --- a/src/cpl_cli/_templates/new/__init__.py +++ b/src/cpl_cli/_templates/new/__init__.py @@ -15,11 +15,11 @@ __title__ = 'cpl_cli._templates.new' __author__ = 'Sven Heidemann' __license__ = 'MIT' __copyright__ = 'Copyright (c) 2020 - 2021 sh-edraft.de' -__version__ = '2021.11.0.post3' +__version__ = '2021.11.0.post4' from collections import namedtuple # imports: VersionInfo = namedtuple('VersionInfo', 'major minor micro') -version_info = VersionInfo(major='2021', minor='11', micro='0.post3') +version_info = VersionInfo(major='2021', minor='11', micro='0.post4') diff --git a/src/cpl_cli/_templates/new/console/__init__.py b/src/cpl_cli/_templates/new/console/__init__.py index 41c21d49..28660773 100644 --- a/src/cpl_cli/_templates/new/console/__init__.py +++ b/src/cpl_cli/_templates/new/console/__init__.py @@ -15,11 +15,11 @@ __title__ = 'cpl_cli._templates.new.console' __author__ = 'Sven Heidemann' __license__ = 'MIT' __copyright__ = 'Copyright (c) 2020 - 2021 sh-edraft.de' -__version__ = '2021.11.0.post3' +__version__ = '2021.11.0.post4' from collections import namedtuple # imports: VersionInfo = namedtuple('VersionInfo', 'major minor micro') -version_info = VersionInfo(major='2021', minor='11', micro='0.post3') +version_info = VersionInfo(major='2021', minor='11', micro='0.post4') diff --git a/src/cpl_cli/_templates/new/console/source/__init__.py b/src/cpl_cli/_templates/new/console/source/__init__.py index 6d492e8f..f4038de7 100644 --- a/src/cpl_cli/_templates/new/console/source/__init__.py +++ b/src/cpl_cli/_templates/new/console/source/__init__.py @@ -15,11 +15,11 @@ __title__ = 'cpl_cli._templates.new.console.source' __author__ = 'Sven Heidemann' __license__ = 'MIT' __copyright__ = 'Copyright (c) 2020 - 2021 sh-edraft.de' -__version__ = '2021.11.0.post3' +__version__ = '2021.11.0.post4' from collections import namedtuple # imports: VersionInfo = namedtuple('VersionInfo', 'major minor micro') -version_info = VersionInfo(major='2021', minor='11', micro='0.post3') +version_info = VersionInfo(major='2021', minor='11', micro='0.post4') diff --git a/src/cpl_cli/_templates/new/console/source/name/__init__.py b/src/cpl_cli/_templates/new/console/source/name/__init__.py index 923b1511..2999941a 100644 --- a/src/cpl_cli/_templates/new/console/source/name/__init__.py +++ b/src/cpl_cli/_templates/new/console/source/name/__init__.py @@ -15,11 +15,11 @@ __title__ = 'cpl_cli._templates.new.console.source.name' __author__ = 'Sven Heidemann' __license__ = 'MIT' __copyright__ = 'Copyright (c) 2020 - 2021 sh-edraft.de' -__version__ = '2021.11.0.post3' +__version__ = '2021.11.0.post4' from collections import namedtuple # imports: VersionInfo = namedtuple('VersionInfo', 'major minor micro') -version_info = VersionInfo(major='2021', minor='11', micro='0.post3') +version_info = VersionInfo(major='2021', minor='11', micro='0.post4') diff --git a/src/cpl_cli/_templates/new/console/source/tests/__init__.py b/src/cpl_cli/_templates/new/console/source/tests/__init__.py index b29d3b89..800301c8 100644 --- a/src/cpl_cli/_templates/new/console/source/tests/__init__.py +++ b/src/cpl_cli/_templates/new/console/source/tests/__init__.py @@ -15,11 +15,11 @@ __title__ = 'cpl_cli._templates.new.console.source.tests' __author__ = 'Sven Heidemann' __license__ = 'MIT' __copyright__ = 'Copyright (c) 2020 - 2021 sh-edraft.de' -__version__ = '2021.11.0.post3' +__version__ = '2021.11.0.post4' from collections import namedtuple # imports: VersionInfo = namedtuple('VersionInfo', 'major minor micro') -version_info = VersionInfo(major='2021', minor='11', micro='0.post3') +version_info = VersionInfo(major='2021', minor='11', micro='0.post4') diff --git a/src/cpl_cli/_templates/new/library/__init__.py b/src/cpl_cli/_templates/new/library/__init__.py index bb5d1046..f6ec8635 100644 --- a/src/cpl_cli/_templates/new/library/__init__.py +++ b/src/cpl_cli/_templates/new/library/__init__.py @@ -15,11 +15,11 @@ __title__ = 'cpl_cli._templates.new.library' __author__ = 'Sven Heidemann' __license__ = 'MIT' __copyright__ = 'Copyright (c) 2020 - 2021 sh-edraft.de' -__version__ = '2021.11.0.post3' +__version__ = '2021.11.0.post4' from collections import namedtuple # imports: VersionInfo = namedtuple('VersionInfo', 'major minor micro') -version_info = VersionInfo(major='2021', minor='11', micro='0.post3') +version_info = VersionInfo(major='2021', minor='11', micro='0.post4') diff --git a/src/cpl_cli/_templates/new/library/source/__init__.py b/src/cpl_cli/_templates/new/library/source/__init__.py index 80427e98..c59be250 100644 --- a/src/cpl_cli/_templates/new/library/source/__init__.py +++ b/src/cpl_cli/_templates/new/library/source/__init__.py @@ -15,11 +15,11 @@ __title__ = 'cpl_cli._templates.new.library.source' __author__ = 'Sven Heidemann' __license__ = 'MIT' __copyright__ = 'Copyright (c) 2020 - 2021 sh-edraft.de' -__version__ = '2021.11.0.post3' +__version__ = '2021.11.0.post4' from collections import namedtuple # imports: VersionInfo = namedtuple('VersionInfo', 'major minor micro') -version_info = VersionInfo(major='2021', minor='11', micro='0.post3') +version_info = VersionInfo(major='2021', minor='11', micro='0.post4') diff --git a/src/cpl_cli/_templates/new/library/source/name/__init__.py b/src/cpl_cli/_templates/new/library/source/name/__init__.py index d12a3c4e..c90c46db 100644 --- a/src/cpl_cli/_templates/new/library/source/name/__init__.py +++ b/src/cpl_cli/_templates/new/library/source/name/__init__.py @@ -15,11 +15,11 @@ __title__ = 'cpl_cli._templates.new.library.source.name' __author__ = 'Sven Heidemann' __license__ = 'MIT' __copyright__ = 'Copyright (c) 2020 - 2021 sh-edraft.de' -__version__ = '2021.11.0.post3' +__version__ = '2021.11.0.post4' from collections import namedtuple # imports: VersionInfo = namedtuple('VersionInfo', 'major minor micro') -version_info = VersionInfo(major='2021', minor='11', micro='0.post3') +version_info = VersionInfo(major='2021', minor='11', micro='0.post4') diff --git a/src/cpl_cli/_templates/new/library/source/tests/__init__.py b/src/cpl_cli/_templates/new/library/source/tests/__init__.py index 71786d42..461a3155 100644 --- a/src/cpl_cli/_templates/new/library/source/tests/__init__.py +++ b/src/cpl_cli/_templates/new/library/source/tests/__init__.py @@ -15,11 +15,11 @@ __title__ = 'cpl_cli._templates.new.library.source.tests' __author__ = 'Sven Heidemann' __license__ = 'MIT' __copyright__ = 'Copyright (c) 2020 - 2021 sh-edraft.de' -__version__ = '2021.11.0.post3' +__version__ = '2021.11.0.post4' from collections import namedtuple # imports: VersionInfo = namedtuple('VersionInfo', 'major minor micro') -version_info = VersionInfo(major='2021', minor='11', micro='0.post3') +version_info = VersionInfo(major='2021', minor='11', micro='0.post4') diff --git a/src/cpl_cli/_templates/publish/__init__.py b/src/cpl_cli/_templates/publish/__init__.py index e8e0cdd0..53c4be16 100644 --- a/src/cpl_cli/_templates/publish/__init__.py +++ b/src/cpl_cli/_templates/publish/__init__.py @@ -15,11 +15,11 @@ __title__ = 'cpl_cli._templates.publish' __author__ = 'Sven Heidemann' __license__ = 'MIT' __copyright__ = 'Copyright (c) 2020 - 2021 sh-edraft.de' -__version__ = '2021.11.0.post3' +__version__ = '2021.11.0.post4' from collections import namedtuple # imports: VersionInfo = namedtuple('VersionInfo', 'major minor micro') -version_info = VersionInfo(major='2021', minor='11', micro='0.post3') +version_info = VersionInfo(major='2021', minor='11', micro='0.post4') diff --git a/src/cpl_cli/command/__init__.py b/src/cpl_cli/command/__init__.py index 041736f4..20d2149e 100644 --- a/src/cpl_cli/command/__init__.py +++ b/src/cpl_cli/command/__init__.py @@ -15,7 +15,7 @@ __title__ = 'cpl_cli.command' __author__ = 'Sven Heidemann' __license__ = 'MIT' __copyright__ = 'Copyright (c) 2020 - 2021 sh-edraft.de' -__version__ = '2021.11.0.post3' +__version__ = '2021.11.0.post4' from collections import namedtuple @@ -28,4 +28,4 @@ from .publish_service import PublishService from .version_service import VersionService VersionInfo = namedtuple('VersionInfo', 'major minor micro') -version_info = VersionInfo(major='2021', minor='11', micro='0.post3') +version_info = VersionInfo(major='2021', minor='11', micro='0.post4') diff --git a/src/cpl_cli/configuration/__init__.py b/src/cpl_cli/configuration/__init__.py index 3b245b84..227c2628 100644 --- a/src/cpl_cli/configuration/__init__.py +++ b/src/cpl_cli/configuration/__init__.py @@ -15,7 +15,7 @@ __title__ = 'cpl_cli.configuration' __author__ = 'Sven Heidemann' __license__ = 'MIT' __copyright__ = 'Copyright (c) 2020 - 2021 sh-edraft.de' -__version__ = '2021.11.0.post3' +__version__ = '2021.11.0.post4' from collections import namedtuple @@ -30,4 +30,4 @@ from .workspace_settings import WorkspaceSettings from .workspace_settings_name_enum import WorkspaceSettingsNameEnum VersionInfo = namedtuple('VersionInfo', 'major minor micro') -version_info = VersionInfo(major='2021', minor='11', micro='0.post3') +version_info = VersionInfo(major='2021', minor='11', micro='0.post4') diff --git a/src/cpl_cli/cpl_cli.json b/src/cpl_cli/cpl_cli.json index 5d24e5e5..89abf37f 100644 --- a/src/cpl_cli/cpl_cli.json +++ b/src/cpl_cli/cpl_cli.json @@ -4,7 +4,7 @@ "Version": { "Major": "2021", "Minor": "11", - "Micro": "0.post3" + "Micro": "0.post4" }, "Author": "Sven Heidemann", "AuthorEmail": "sven.heidemann@sh-edraft.de", diff --git a/src/cpl_cli/live_server/__init__.py b/src/cpl_cli/live_server/__init__.py index c0b62dd1..2632f2c9 100644 --- a/src/cpl_cli/live_server/__init__.py +++ b/src/cpl_cli/live_server/__init__.py @@ -15,11 +15,11 @@ __title__ = 'cpl_cli.live_server' __author__ = 'Sven Heidemann' __license__ = 'MIT' __copyright__ = 'Copyright (c) 2020 - 2021 sh-edraft.de' -__version__ = '2021.11.0.post3' +__version__ = '2021.11.0.post4' from collections import namedtuple # imports: VersionInfo = namedtuple('VersionInfo', 'major minor micro') -version_info = VersionInfo(major='2021', minor='11', micro='0.post3') +version_info = VersionInfo(major='2021', minor='11', micro='0.post4') diff --git a/src/cpl_cli/publish/__init__.py b/src/cpl_cli/publish/__init__.py index b2b91c73..b313a93d 100644 --- a/src/cpl_cli/publish/__init__.py +++ b/src/cpl_cli/publish/__init__.py @@ -15,7 +15,7 @@ __title__ = 'cpl_cli.publish' __author__ = 'Sven Heidemann' __license__ = 'MIT' __copyright__ = 'Copyright (c) 2020 - 2021 sh-edraft.de' -__version__ = '2021.11.0.post3' +__version__ = '2021.11.0.post4' from collections import namedtuple @@ -24,4 +24,4 @@ from .publisher_abc import PublisherABC from .publisher_service import PublisherService VersionInfo = namedtuple('VersionInfo', 'major minor micro') -version_info = VersionInfo(major='2021', minor='11', micro='0.post3') +version_info = VersionInfo(major='2021', minor='11', micro='0.post4') diff --git a/src/cpl_cli/source_creator/__init__.py b/src/cpl_cli/source_creator/__init__.py index bbe761ce..bf551165 100644 --- a/src/cpl_cli/source_creator/__init__.py +++ b/src/cpl_cli/source_creator/__init__.py @@ -15,11 +15,11 @@ __title__ = 'cpl_cli.source_creator' __author__ = 'Sven Heidemann' __license__ = 'MIT' __copyright__ = 'Copyright (c) 2020 - 2021 sh-edraft.de' -__version__ = '2021.11.0.post3' +__version__ = '2021.11.0.post4' from collections import namedtuple # imports: VersionInfo = namedtuple('VersionInfo', 'major minor micro') -version_info = VersionInfo(major='2021', minor='11', micro='0.post3') +version_info = VersionInfo(major='2021', minor='11', micro='0.post4') diff --git a/src/cpl_core/console/console.py b/src/cpl_core/console/console.py index 7084bba2..6f819355 100644 --- a/src/cpl_core/console/console.py +++ b/src/cpl_core/console/console.py @@ -402,7 +402,8 @@ class Console: cls._show_select_menu() with keyboard.Listener( - on_press=cls._select_menu_key_press, suppress=True) as listener: + on_press=cls._select_menu_key_press, suppress=False + ) as listener: listener.join() Console.color_reset() diff --git a/src/cpl_core/cpl_core.json b/src/cpl_core/cpl_core.json index 773a37bd..15ba0caa 100644 --- a/src/cpl_core/cpl_core.json +++ b/src/cpl_core/cpl_core.json @@ -18,15 +18,15 @@ "Dependencies": [ "colorama==0.4.4", "mysql-connector==2.2.9", - "psutil==5.8.0", + "psutil==5.9.0", "packaging==21.3", "pyfiglet==0.8.post1", - "pynput==1.7.5", - "setuptools==59.4.0", + "pynput==1.7.6", + "setuptools==60.5.0", "tabulate==0.8.9", "termcolor==1.1.0", "watchdog==2.1.6", - "wheel==0.37.0" + "wheel==0.37.1" ], "PythonVersion": ">=3.8", "PythonPath": {}, diff --git a/src/tests/custom/console/main.py b/src/tests/custom/console/main.py index d61cd44c..12889c57 100644 --- a/src/tests/custom/console/main.py +++ b/src/tests/custom/console/main.py @@ -17,23 +17,22 @@ def test_console(): if __name__ == '__main__': Console.write_line('Hello World\n') - Console.spinner('Test:', test_spinner, spinner_foreground_color=ForegroundColorEnum.cyan, - text_foreground_color='green') - # opts = [ - # 'Option 1', - # 'Option 2', - # 'Option 3', - # 'Option 4' - # ] - # selected = Console.select( - # '>', - # 'Select item:', - # opts, - # header_foreground_color=ForegroundColorEnum.blue, - # option_foreground_color=ForegroundColorEnum.green, - # cursor_foreground_color=ForegroundColorEnum.red - # ) - # Console.write_line(f'You selected: {selected}') + # Console.spinner('Test:', test_spinner, spinner_foreground_color=ForegroundColorEnum.cyan, text_foreground_color='green') + opts = [ + 'Option 1', + 'Option 2', + 'Option 3', + 'Option 4' + ] + selected = Console.select( + '>', + 'Select item:', + opts, + header_foreground_color=ForegroundColorEnum.blue, + option_foreground_color=ForegroundColorEnum.green, + cursor_foreground_color=ForegroundColorEnum.red + ) + Console.write_line(f'You selected: {selected}') # test_console() Console.write_line()