-
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile
49 lines (35 loc) · 985 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
39
40
41
42
43
44
45
46
47
48
NAME = steam-search
.venv/bin/activate: requirements.txt
python3 -m venv .venv
./.venv/bin/pip install -r requirements.txt
./.venv/bin/pip install -r requirements-dev.txt
.PHONY: venv
venv: .venv/bin/activate
build: .venv/bin/activate
mkdir -p build
./.venv/bin/python3 -m pip install -r requirements.txt --target build
cp -r src/* build
dist: build
mkdir -p dist
python3 -m zipapp build -p "/usr/bin/env python" -o dist/$(NAME).pyz
/home/garulf/.config/rofi/scripts/$(NAME).pyz: dist
mkdir -p ~/.config/rofi/scripts
cp dist/$(NAME).pyz ~/.config/rofi/scripts
.PHONY: install
install: /home/garulf/.config/rofi/scripts/$(NAME).pyz
run: install
rofi -modi "$(NAME)" -show "$(NAME)"
.PHONY: uninstall
uninstall:
rm -f ~/.config/rofi/scripts/$(NAME).pyz
.PHONY: clean
clean: uninstall
rm -rf dist
rm -rf build
rm -rf .venv
.PHONY: update
update:
pip-compile --upgrade requirements.in
.PHONY: update-dev
update-dev:
pip-compile --upgrade requirements-dev.in