- Configurable package creation with "sensible defaults".
- "Open Source First" package creation with pre-configured CI-CD.
- Industry Standard tooling capabilities.
- Python 2.7+, Python 3.4+ and PyPy aware boilerplate.
pip install -q cookiecutter && cookiecutter gh:achillesrasquinha/boilpy
For an exhaustive installation guide, you can visit the Documentation here.
boilpy provides you a production-ready template out of the box! For most tasks, boilpy consists of a well-defined Makefile
which can be used to run make
commands within your project directory.
In order to get started, we recommend you to create a .env
file within your project directory in order to configure some of the environment variables declared within the Makefile
. You can override the environment variables defined here. To override some of the environment variables, you could also declare them at run-time as follows:
foo@bar:~/foobar$ FOO=BAR BAR=BAZ make [command]
First, create an isolated virtual environment for your package using virtualenv
:
foo@bar:~/foobar$ make env
β [20:37:10] Creating a Virtual Environment .venv with Python - /usr/bin/python
Simply install your package as follows:
foo@bar:~/foobar$ make install
β [20:38:23] Cleaning Python Cache
β [20:38:23] Cleaning Successful
β [20:38:23] Building Requirements
β [20:38:23] Installing Requirements
β [20:38:23] Installing foobar (development)
β [20:38:23] Installation Successful
To check if your package works, launch the shell:
foo@bar:~/foobar$ make shell
...and then simply import your package as follows:
In [1]: import foobar as fb
In [2]: fb.__name__
Out[2]: 'foobar'
To check if the command-line interface works, activate the virtual environment:
foo@bar:~/foobar$ source .venv/bin/activate
...and then simply type the command:
foo@bar:~/foobar$ foobar
Usage: foobar [OPTIONS] COMMAND [ARGS]...
A foobar package
Options:
--version Show the version and exit.
-h, --help Show this message and exit.
Commands:
help Show this message and exit.
version Show version and exit.
This repository has been released under the MIT License.