If you wish to contribute to DJ Tools, please follow these development rules:
- Development branches must:
- be linked to an Issue
- branch from
release/*
- have a concise name for the feature or bugfix specifically targeted by that branch (e.g.
xml-track-randomization
orimprove-spotify-stability
)
- Commits must:
- have messages that follow the Conventional Commits standard
- (if non-trivial) have messages that include a
Why?
andWhat?
section in the body describing the reason for and specifics of the commit - (if relevant) include updates to the docs
On push
events (with **.py
changes) to feature branches, the format Action will run the black code formatter and commit changes if there are any.
On pull_request
events (with src/**.py
or tests/**.py
changes) the test-lint Action is triggered. For build checks to pass on the PR, this Action must have 100%
test passing and coverage and a 10.00/10
linting score:
- if you're unable to pass tests with
100%
coverage, please open an issue - if you're not getting a
10.00/10
lint score, first attempt to correct the errors before resorting to messages control
On push
events to release/**
the following Actions are triggered:
- release-dev (with
src/**.py
changes) - deploy-dev-docs (with
src/**.py
ordocs/**.md
changes)
On push
events to main
, for the same file change patterns, the deploy-prod-docs and release-prod Actions are triggered.
pyenv virtualenv $(pyenv global) djtools-dev && \
pyenv activate djtools-dev && \
pip install -e ".[dev]"
pytest --cov --cov-report term-missing
pylint $(git ls-files '*.py')
black .