-
Notifications
You must be signed in to change notification settings - Fork 545
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add pre-commit and pre-commit-ci with the following hooks: - pycln for cleaning up unused imports. - isort for sorting imports. - black for formatting code. For more info see `docs/developers.rst`. Also: - Changed tox config: - Added environments for pre-commit. - Removed some redundant options. - Created a covreport environment for reporting coverage for all environments. - Make it possible to run a custom command instead of pytest. - Make it possible to run an extra command - Make it possible to change the mypy command - Use extras instead of using requirements files. - Update setup.py - Remove berkleydb and networkx from tests_require and tests extra group as they are not always needed for tests. - Added separate extra groups for berkleydb and networkx - Added a dev extras group with dev tools. - Update github actions - Use tox to run tests. - Run flake8 only once. - Change docs job to rather be more generic for potential future tox environments.
- Loading branch information
Showing
8 changed files
with
167 additions
and
67 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
--- | ||
ci: | ||
# https://pre-commit.ci/#configuration | ||
autoupdate_schedule: weekly | ||
autofix_prs: false | ||
|
||
repos: | ||
- repo: https://github.com/hadialqattan/pycln | ||
rev: v1.1.0 | ||
hooks: | ||
- id: pycln | ||
- repo: https://github.com/PyCQA/isort | ||
rev: 5.10.1 | ||
hooks: | ||
- id: isort | ||
additional_dependencies: [toml] | ||
- repo: https://github.com/psf/black | ||
# WARNING: rev should be the same as in `black.toml`. | ||
rev: 21.9b0 | ||
hooks: | ||
- id: black |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters