forked from nipreps/niworkflows
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile
39 lines (30 loc) · 878 Bytes
/
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
VERSION := $(shell python -c "import niworkflows; print niworkflows.info.__version__")
.PHONY: clean-pyc
clean-pyc:
find . -name '__pycache__' -type d -exec rm -r {} +
find . -name '*.pyc' -exec rm --force {} +
find . -name '*.pyo' -exec rm --force {} +
find . -name '*~' -exec rm --force {} +
.PHONY: clean-build
clean-build:
rm --force --recursive build/
rm --force --recursive dist/
rm --force --recursive *.egg-info
rm --force --recursive src/
.PHONY: tag
tag:
git tag -a $(VERSION) -m "Version ${VERSION}"
git push origin $(VERSION)
.PHONY: test
test: clean-pyc
py.test --ignore=src/ --verbose $(TEST_PATH)
dist: clean-build clean-pyc
python setup.py sdist
.PHONY: tag-release
release: clean-build
python setup.py sdist
twine upload dist/*
.PHONY: tag-release
tag-release: clean-build tag
python setup.py sdist
twine upload dist/*