{"repo":"relastle/glacier","free":true,"listed":false,"github":"https://github.com/relastle/glacier","clone":"git clone https://github.com/relastle/glacier.git","description":":snowflake: Building Python CLI using docstrings and typehints :snake:","language":"Python","stars":98,"topics":["python","python3","productivity","cli","command-line-tool","library","docstring","python-cli","asyncio"],"license":"MIT","category":"cli-tools","readme_excerpt":"glacier glacier is a python CLI building library for minimalists. glacier Installation Quick start Basic Usage CLI without subcommand CLI with subcommands Pass a list of functions Pass a dictionary of functions Async entrypoint support Positional argument Options Default value for optional argument Help with docstring Google Style Numpy Style reStructuredText Style Supported types Note Philosophy Warnings Related works LICENSE Installation Quick start You only have to call glacier against the entrypoint function. Then, you can see help 🍰. Basic Usage CLI without subcommand If you just call glacier to a function, it will invoke it as stand-alone CLI (like the example in Quick start). CLI with subcommands You can easily construct CLI with subcommands in the following two ways. Pass a list of functions If you passes a lift of function, glacier constructs the CLI with subcommands whose names are the same as the declared function names. In this example, the subcommans will be run , build , and test . Pass a dictionary of functions You can easily give the different name as the subcommand name from any declared name of the function. Just give a dictionary (key will be a subcommand name). This works exactly the same as the previous example. This interface makes it very easy to build a simple CLI tool from an existing project. Async entrypoint support You sometimes want your async function to be a CLI entrypoint. Only you have to do is just passing the async function as if it were sy","default_branch":null,"files":null,"tree":[],"storefront":"/r/relastle","claimed":false,"request_supported":{"post":"https://gitbuyer.com/r/relastle/glacier/request-supported","requests":0},"note":"indexed from public GitHub; nothing is for sale on this page. Clone it from GitHub. Paid listings live at /search."}