forked from flaport/sax
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathMakefile
67 lines (52 loc) · 1.29 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
.ONESHELL:
SHELL := /bin/bash
SRC = $(wildcard nbs/*.ipynb)
all: sax docs
.SILENT: docker
docker:
sed -i "s/^[ ]*-[ ]\bsax\b.*//g" environment.yml
sed -i "s/\$${RPYPI_USER}/${RPYPI_USER}/g" environment.yml
sed -i "s/\$${RPYPI_TOKEN}/${RPYPI_TOKEN}/g" environment.yml
-docker build . -t sax
git checkout -- environment.yml
sax: $(SRC)
nbdev_build_lib
lib:
nbdev_build_lib
sync:
nbdev_update_lib
serve:
cd docs && bundle exec jekyll serve
.PHONY: docs
docs:
jupyter nbconvert --execute --inplace index.ipynb
nbdev_build_docs
run:
find . -name "*.ipynb" | grep -v ipynb_checkpoints | xargs -I {} papermill {} {}
test:
nbdev_test_nbs
release: pypi conda_release
nbdev_bump_version
conda_release:
fastrelease_conda_package
pypi: dist
twine upload --repository pypi dist/*
dist: clean
python -m build --sdist --wheel
clean:
nbdev_clean_nbs
find . -name "*.ipynb" | xargs nbstripout
find . -name "dist" | xargs rm -rf
find . -name "build" | xargs rm -rf
find . -name "builds" | xargs rm -rf
find . -name "__pycache__" | xargs rm -rf
find . -name "*.so" | xargs rm -rf
find . -name "*.egg-info" | xargs rm -rf
find . -name ".ipynb_checkpoints" | xargs rm -rf
find . -name ".pytest_cache" | xargs rm -rf
reset:
rm -rf sax
rm -rf docs
git checkout -- docs
nbdev_build_lib
make clean