Contributing to Map'A'Droid
The following summarizes the process for contributing changes.
Map'A'Droid utilizes make
to build a consistent development environment across platforms. This helps ensure that any changes made pass required unit-tests and can identify regressions. To utilize make
the following requirements need to be met:
- Make
- pip
- pre-commit
- docker
- docker-compose
- Python
Some of the dependencies will give additional information if its not installed.
Make Commands
The following make
commands are available:
setup
- Install pre-commit and install the required git hooks. This should be run whenever new hooks are added (should be rare since most will be handled by pre-commit).clean
- Stop containers related to MAD development and cleanup ./tox folderbuild
- Multi-stage docker build. Build the MAD base image (local_mad_production) and build the development image (local_mad_development) without using the cacherebuild
- Same asbuild
but can re-use cacheup
- Start MariaDB and local_mad_development containers. MariaDB container does not have a persistent volumedown
- Execute MariaDB and local_mad_development containersshell
- Executeup
and gives user-level access to local_mad_development containerroot-shell
- Executeup
and gives root-level access to local_mad_development containerrun
- Start MariaDB and local_mad_development containers. MariaDB container has a persistent volumetests
- Executeup
and run all tests through toxunittests
- Executeup
and run tox tests for py37shell-<pyxx>
- Executeup
and grant user-level access with the tox virtual environment selected. IncludingRECREATE=1
will rebuild the tox environmentversions
- Lookup the current version for pip, pre-commit, docker, and docker-compose