Skip to content

Template repository to build Python CLI tools with poetry support

License

Notifications You must be signed in to change notification settings

ZappaBoy/python-cli-tool-template

Repository files navigation

example_tool

example_tool is a template repository to build Python CLI tool.

Installation

This tool uses poetry to manage dependencies and packaging. To install all the dependencies simply run:

poetry install

Usage

You can run the tool using poetry:

poetry run example_tool --help

Or you can run the tool using python:

python -m example_tool --help

Or you can run the tool directly from the directory or add it to your path:

example_tool --help
usage: example_tool [-h] [--verbose] [--debug] [--quiet | --no-quiet | -q] [--version]

This is a template repository to build Python CLI tool.

options:
  -h, --help            show this help message and exit
  --verbose, -v         Increase verbosity. Use more than once to increase verbosity level (e.g. -vvv).
  --debug               Enable debug mode.
  --quiet, --no-quiet, -q
                        Do not print any output/log
  --version             Show version and exit.

Development

Testing

To run the tests simply run:

poetry run test

Update setup.py

To update the setup.py file with the latest dependencies and versions run:

poetry run poetry2setup > setup.py

Acknowledgements

This project was generated using powerful tools and libraries such as poetry, pydantic, pytest and more, I simply put the pieces together. Please check and support all the tools and libraries used in this project.

About

Template repository to build Python CLI tools with poetry support

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Sponsor this project

 

Packages

No packages published

Languages