summaryrefslogtreecommitdiff
path: root/ui/Makefile
blob: 594e2e3acbd54449f1a9c2c44ab9ce4e47ff608f (plain)
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
#
# builds for development mode
#

dev-build: build-clean make-init
	npm install
	npm run build

dev-install: dev-build
	pip install -e pydist

# installs a prebuilt python package from
# the magical pypi place in the sky.
# for usage when you don't want to install nodejs
dev-install-prebuilt:
	pip install -U leap.bitmask_js

#
# distribution builds
#

dist-build: build-clean make-init
	npm install
	npm run build:production
	cd pydist && python setup.py bdist_wheel

dist-upload:
	cd pydist && python setup.py sdist upload -r pypi

dist-install: dist-build
	pip install pydist/dist/*.whl

#
# clean up and set up
#

make-init:
	test -d pydist/leap/bitmask_js || mkdir -p pydist/leap/bitmask_js
	touch pydist/leap/bitmask_js/__init__.py

build-clean:
	rm -rf pydist/leap/bitmask_js
	rm -rf pydist/dist
	rm -rf pydist/build

clean: build-clean
	rm -rf node_modules

uninstall:
	pip uninstall leap.bitmask_js