-
Notifications
You must be signed in to change notification settings - Fork 2
/
Makefile
52 lines (36 loc) · 1.07 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
SUBDIR_GOALS= all clean distclean
SUBDIR+= src/canvaslms
SUBDIR+= doc
SUBDIR+= docker
version=$(shell sed -n 's/^ *version *= *\"\([^\"]\+\)\"/\1/p' pyproject.toml)
.PHONY: all
all: compile doc/canvaslms.pdf
.PHONY: install
install: compile
python3 -m pip install -e .
register-python-argcomplete canvaslms > canvaslms.bash
sudo install canvaslms.bash /etc/bash_completion.d/
rm canvaslms.bash
.PHONY: compile
compile:
${MAKE} -C src/canvaslms all
poetry build
.PHONY: publish publish-github publish-canvaslms publish-docker
publish: publish-canvaslms doc/canvaslms.pdf publish-docker publish-github
publish-github: doc/canvaslms.pdf
git push
gh release create -t v${version} v${version} doc/canvaslms.pdf
doc/canvaslms.pdf: $(wildcard src/canvaslms/cli/*.tex)
${MAKE} -C $(dir $@) $(notdir $@)
publish-canvaslms: compile
poetry publish
publish-docker:
sleep 60
${MAKE} -C docker publish
.PHONY: clean
clean:
.PHONY: distclean
distclean:
${RM} -R build dist canvaslms.egg-info src/canvaslms.egg-info
INCLUDE_MAKEFILES=makefiles
include ${INCLUDE_MAKEFILES}/subdir.mk