-
Notifications
You must be signed in to change notification settings - Fork 55
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'master' into get-users
- Loading branch information
Showing
21 changed files
with
639 additions
and
487 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
repos: | ||
- repo: https://github.com/pre-commit/pre-commit-hooks | ||
rev: v4.1.0 | ||
hooks: | ||
- id: trailing-whitespace | ||
- id: end-of-file-fixer | ||
- id: mixed-line-ending | ||
args: ['--fix=lf'] | ||
description: Forces to replace line ending by the UNIX 'lf' character. | ||
- repo: https://github.com/psf/black | ||
rev: 22.1.0 | ||
hooks: | ||
- id: black | ||
language_version: python3 | ||
args: [-t, py310] |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,47 @@ | ||
.PHONY: help dev clean update test lint pre-commit | ||
|
||
VENV_NAME?=venv | ||
VENV_ACTIVATE=. $(VENV_NAME)/bin/activate | ||
PYTHON=${VENV_NAME}/bin/python3 | ||
|
||
.DEFAULT: help | ||
help: | ||
@echo "make dev" | ||
@echo " prepare development environment, use only once" | ||
@echo "make clean" | ||
@echo " delete development environment" | ||
@echo "make update" | ||
@echo " update dependencies" | ||
@echo "make test" | ||
@echo " run tests" | ||
@echo "make lint" | ||
@echo " run black" | ||
@echo "make pre-commit" | ||
@echo " run pre-commit hooks" | ||
|
||
dev: | ||
make venv | ||
|
||
venv: $(VENV_NAME)/bin/activate | ||
$(VENV_NAME)/bin/activate: | ||
test -d $(VENV_NAME) || virtualenv -p python3 $(VENV_NAME) | ||
${PYTHON} -m pip install -U pip | ||
${PYTHON} -m pip install -r dev_requirements.txt | ||
$(VENV_NAME)/bin/pre-commit install | ||
touch $(VENV_NAME)/bin/activate | ||
|
||
clean: | ||
rm -rf venv | ||
|
||
update: | ||
${PYTHON} -m pip install -U -r dev_requirements.txt | ||
$(VENV_NAME)/bin/pre-commit install | ||
|
||
test: venv | ||
${PYTHON} -m pytest | ||
|
||
lint: venv | ||
$(VENV_NAME)/bin/black -t py310 --exclude $(VENV_NAME) . | ||
|
||
pre-commit: venv | ||
$(VENV_NAME)/bin/pre-commit |
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 |
---|---|---|
@@ -1,4 +1,6 @@ | ||
python-ldap==3.2.0 # here instead of requirements.txt so rtfd can build | ||
black==24.3.0 | ||
pre-commit==2.17.0 | ||
python-ldap==3.4.0 # here instead of requirements.txt so rtfd can build | ||
Sphinx==2.1.2 | ||
|
||
-r requirements.txt |
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
Oops, something went wrong.