This project was created using footing. For more information about footing, go to the footing docs.
Set up your development environment with:
git clone [email protected]:Opus10/django-pghistory.git
cd django-pghistory
make docker-setup
make docker-setup
will set up a development environment managed by Docker. Install docker here and be sure it is running when executing any of the commands below.
If you prefer a native development environment, make conda-setup
will set up a development environment managed by Conda. Dependent services, such as databases, must be ran manually.
Run the tests on one Python version with:
make test
Run the full test suite against all supported Python versions with:
make full-test-suite
Validate the code with:
make lint
If your code fails the linter checks, fix common errors with:
make lint-fix
This project uses git-tidy to produce structured commits with git trailers. Information from commit messages is used to generate release notes and bump the version properly.
To do a structured commit with git-tidy
, do:
make tidy-commit
All commits in a pull request must be tidy commits that encapsulate a change. Ideally entire features or bug fixes are encapsulated in a single commit. Squash all of your commits into a tidy commit with:
make tidy-squash
To check if your commits pass linting, do:
make tidy-lint
Note, the above command lints every commit since branching from main. You can also run make shell
and run git tidy
commands inside the docker environment to do other flavors of git tidy
commands.
Mkdocs Material documentation can be built with:
make docs
A shortcut for serving them is:
make docs-serve
Anything that is merged into the main branch will be automatically deployed to PyPI. Documentation will be published to a ReadTheDocs at https://django-pghistory.readthedocs.io/
.
The following files will be generated and should not be edited by a user:
CHANGELOG.md
- Contains an automatically-generated change log for each release.
This project uses Semantic Versioning by analyzing Type:
trailers on git commit messages (trailers are added when using git tidy-commit
). In order to bump the minor version, use "feature" or "bug" as the type. In order to bump the major version, use "api-break". The patch version will be updated automatically if none of these tags are present.