forked from django-webpack/django-webpack-loader
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathMakefile
37 lines (27 loc) · 833 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
.PHONY: clean build deploy install publish
# Project settings
PROJECT = webpack-loader
# Virtual environment settings
ENV ?= venv
REPOSITORY ?= pypi
requirements = -r requirements-dev.txt
all: install build
clean:
@echo "Cleaning..."
@find webpack_loader/ -name '*.pyc' -delete
@rm -rf ./build ./*egg* ./.coverage ./dist
build: clean
@echo "Building..."
@python setup.py sdist bdist_wheel --universal
install:
@echo "Installing build dependencies"
@[ ! -d $(ENV)/ ] && virtualenv $(ENV)/ || :
@$(ENV)/bin/pip install $(requirements)
generate-rst:
@pandoc --from=markdown --to=rst --output=README.rst README.md
publish: generate-rst build
@echo "Publishing to pypi..."
@$(ENV)/bin/twine upload -r $(REPOSITORY) dist/*
register:
@echo "Registering package on pypi..."
@$(ENV)/bin/twine register -r $(REPOSITORY)