Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Refactor - split up functions into files #54

Merged
merged 10 commits into from
Feb 12, 2021
Merged

Refactor - split up functions into files #54

merged 10 commits into from
Feb 12, 2021

Conversation

LoLei
Copy link
Owner

@LoLei LoLei commented Feb 10, 2021

For now this adds directories and files which have code split up and grouped together according to functionality.

In a future refactoring step, classes could be used as well, to avoid passing around arguments that much.
Also, more type hints should be used, although I'm hesitant to go too fancy with that, as older Python versions might not support the newer type hint features. There is no minimum Python version requirement at the moment, although one could theoretically be set.

razer_cli/listing/lister.py Outdated Show resolved Hide resolved
@GM-Script-Writer-62850
Copy link

GM-Script-Writer-62850 commented Feb 11, 2021

on the note of python version lets include that in --version output

print("Python:", '.'.join([str(sys.version_info.major), str(sys.version_info.minor), str(sys.version_info.micro)]))

just add at the end of the if args.version: block in razer_cli.py

note that this pull request drops import sys from the razer_cli.py file which is needed for that

@GM-Script-Writer-62850
Copy link

GM-Script-Writer-62850 commented Feb 11, 2021

i do not see anything broken with a quick test; python 3.8

@LoLei LoLei merged commit 0ac8875 into master Feb 12, 2021
@LoLei LoLei deleted the feature/refactor branch February 12, 2021 14:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants