Python ul py tool
Project description
ul-py-tool
This library allows to bootstrap Python UnicLab project from scratch. It provides a set of useful CMD commands mapping in main.py file.
def main() -> None:
Cmd.main({
'code_stats': 'ul_py_tool.commands.cmd_stats:CmdStats',
'minor': 'ul_py_tool.commands.cmd_version:CmdVersionMinor',
'major': 'ul_py_tool.commands.cmd_version:CmdVersionMajor',
'patch': 'ul_py_tool.commands.cmd_version:CmdVersionPatch',
'lint': 'ul_py_tool.commands.cmd_lint:CmdLint',
'install': 'ul_py_tool.commands.cmd_install:CmdInstall',
'test': 'ul_py_tool.commands.cmd_test:CmdTest',
'fmt': 'ul_py_tool.commands.cmd_fmt:CmdFmt',
'release': 'ul_py_tool.commands.cmd_release:CmdRelease',
'test_secrets': 'ul_py_tool.commands.cmd_test_secrets.py:CmdTestSecrets',
'build-images': 'ul_py_tool.commands.cmd_build_images:CmdBuildImages',
'outdated': 'ul_py_tool.commands.cmp_outdated:CmdOutdated',
'cleanup': 'ul_py_tool.commands.cmd_cleanup:CmdCleanup',
'fix_own': 'ul_py_tool.commands.cmd_fix_own:CmdFixOwn',
})
This maps the code of the CMD command to its name. After mapping, we can use a command like this:
python -m FOLDER_NAME_WHERE_MAIN_PY_LOCATED command_name
python -m src run_some_script # main.py located in src/ root
Command | Desription |
---|---|
Cmd | Base class. Each command should inherit from it and provide method run(). |
CmdStats | Command that provides us statistics about service, lines of code written, etc. |
CmdVersion | Command that applies a versioning to setup.py (major, minor, patch). |
CmdTest | Command that runs tests. |
CmdRelease | Command for making a release. |
CmdLint | Command to run lint (different steps). |
CmdFmt | Command to apply formatting (black, isort (to be implemented)). |
CmdBuildImages | Command that helps to build & push to the registry Docker images. |
CmdInstall | Generates project files, configs, pre-commits, etc. |
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
ul-py-tool-1.15.34.tar.gz
(35.4 kB
view details)
Built Distribution
File details
Details for the file ul-py-tool-1.15.34.tar.gz
.
File metadata
- Download URL: ul-py-tool-1.15.34.tar.gz
- Upload date:
- Size: 35.4 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.1 CPython/3.10.9
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | e60138ae522446c00d92d1b680a10b15101e2c72564ec4fe9d368ad6abe7d830 |
|
MD5 | d6d7b31a4ae9350d17435eeb94fdab83 |
|
BLAKE2b-256 | 0a556db322336802d2eb3a7d0040e409759b36f28140c5372a39e5acd887d904 |
File details
Details for the file ul_py_tool-1.15.34-py3-none-any.whl
.
File metadata
- Download URL: ul_py_tool-1.15.34-py3-none-any.whl
- Upload date:
- Size: 48.7 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.1 CPython/3.10.9
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 4d8e7a8af253287a934edf3f56d4c9123b88fc2898f76296fd0e0beab9427f33 |
|
MD5 | eeb83279a2b68715463f5d18b1dab092 |
|
BLAKE2b-256 | 07687424619d2cdda8902cb245aadb9cd5e487bc188a88e7b68b03a7d352b0d7 |