# python-cli-template
[](https://pypi.org/project/python-cli-template/)
[](https://codecov.io/gh/remarkablemark/python-cli-template)
[](https://github.com/remarkablemark/python-cli-template/actions/workflows/lint.yml)
Python CLI Template
## Quick Start
Greet a name:
```sh
pipx run python-cli-template --name world
```
## Prerequisites
- [Python](https://www.python.org/)
- [pipx](https://pipx.pypa.io/) or [uv](https://docs.astral.sh/uv/)
## CLI
Install with pipx:
```sh
pipx install python-cli-template
```
Or install with uv:
```sh
uv tool install python-cli-template
```
### `--name`
**Optional**: Name to greet. Defaults to `World`.
```sh
python-cli-template --name Alex
```
### `--version`
Show the program's version number and exit:
```sh
python-cli-template --version # python-cli-template -v
```
Show the help message and exit:
```sh
python-cli-template --help # python-cli-template -h
```
## Script
Install the package:
```sh
uv add python-cli-template
```
Greet a name:
```py
# script.py
from python_cli_template import hello
print(hello("Bob"))
```
Run the script:
```sh
uv run script.py
```
## License
[MIT](https://github.com/remarkablemark/python-cli-template/blob/master/LICENSE)