-
Notifications
You must be signed in to change notification settings - Fork 1
/
Makefile
38 lines (26 loc) · 808 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
.DEFAULT_GOAL := install
.bookkeeping/development.txt: .bookkeeping/pip-tools requirements.txt
mkdir -p .bookkeeping
cat requirements.txt > .bookkeeping/development.txt.next
pip install -r .bookkeeping/development.txt.next
pip-sync .bookkeeping/development.txt.next
ifdef PYENV_VIRTUAL_ENV
pyenv rehash
endif
docker compose build --pull
mv .bookkeeping/development.txt.next .bookkeeping/development.txt
.bookkeeping/pip-tools:
mkdir -p .bookkeeping
touch .bookkeeping/pip-tools.next
pip install -U pip pip-tools
ifdef PYENV_VIRTUAL_ENV
pyenv rehash
endif
mv .bookkeeping/pip-tools.next .bookkeeping/pip-tools
%.txt: %.in .bookkeeping/pip-tools
pip-compile --upgrade --output-file $@ $<
.PHONY: install
install: .bookkeeping/development.txt
.PHONY: clean
clean:
rm -Rf .bookkeeping/