forked from CZ-NIC/pyoidc
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile
69 lines (55 loc) · 1.65 KB
/
Makefile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
PROJECT_ROOT:=.
SPHINXOPTS =
SPHINXBUILD = sphinx-build
SPHINXABUILD = sphinx-autobuild
BUILDDIR = doc/_build
DOCDIR = doc/
OICDIR = src/oic
TESTDIR = tests
help:
@echo "Please use \`make <target>' where <target> is one of"
@echo " html to make HTML documentation files"
@echo " livehtml to make HTML documentation files (live reload!)"
@echo " install to install the python dependencies for development"
@echo " test to run the tests"
@echo " isort to sort imports"
@echo " blacken to format the code"
@echo " bandit to run some simple security checkers"
.PHONY: help
clean:
rm -rf $(BUILDDIR)/*
.PHONY: clean
ALLSPHINXOPTS=-W
html:
@pipenv run $(SPHINXBUILD) -b html $(DOCDIR) $(BUILDDIR)/html $(ALLSPHINXOPTS)
@echo "Build finished. The HTML pages are in $(BUILDDIR)/html."
.PHONY: html
livehtml:
@pipenv run $(SPHINXABUILD) -b html $(DOCDIR) $(BUILDDIR)/html $(ALLSPHINXOPTS)
@echo "Build finished. Watching for change ..."
.PHONY: livehtml
install:
@pipenv install --dev -e .[develop,testing,docs,quality,ldap_authn]
.PHONY: install
test:
@pipenv run pytest $(TESTDIR)
.PHONY: test
isort:
@pipenv run isort $(OICDIR) $(TESTDIR)
check-isort:
@pipenv run isort --diff --check-only $(OICDIR) $(TESTDIR)
.PHONY: isort check-isort
blacken:
@pipenv run black src/ tests/
check-black:
@pipenv run black src/ tests/ --check
.PHONY: blacken check-black
bandit:
@pipenv run bandit -a file -r src/ oauth_example/ oidc_example/
.PHONY: bandit
check-pylama:
@pipenv run pylama $(OICDIR) $(TESTDIR)
.PHONY: check-pylama
release:
@pipenv run python setup.py sdist upload -r pypi
.PHONY: release