aboutsummaryrefslogtreecommitdiffstats
path: root/Makefile
diff options
context:
space:
mode:
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile46
1 files changed, 36 insertions, 10 deletions
diff --git a/Makefile b/Makefile
index 74a7976..538e814 100644
--- a/Makefile
+++ b/Makefile
@@ -1,20 +1,46 @@
test: all
- cd solo-tool-project/test && ../../venv/bin/pytest *test.py
+ cd solo-tool-project/test && ../../.venv/bin/pytest *test.py
-all: venv .git/hooks/pre-commit
+all: .venv .git/hooks/pre-commit
clean:
- rm -rf venv
+ rm -rf .venv
.git/hooks/pre-commit: pre-commit
install -m 755 pre-commit .git/hooks/pre-commit
-venv: venv/touchfile
+.venv: .venv/touchfile
-venv/touchfile: requirements.txt solo-tool-project/pyproject.toml cli-project/pyproject.toml gui-project/pyproject.toml
- rm -rf venv
- python -m venv venv
- ./venv/bin/pip install -r requirements.txt
- touch venv/touchfile
+.venv/touchfile: requirements.txt solo-tool-project/pyproject.toml cli-project/pyproject.toml web-project/pyproject.toml
+ rm -rf .venv
+ uv venv
+ uv pip install -r requirements.txt
+ touch .venv/touchfile
-.PHONY: all test clean
+web-deploy: .venv/touchfile
+ ./.venv/bin/solo-tool-web --no-reload --port 80 --refresh 0.2 --session_path="https://files.0xf7.com"
+
+web-dev: .venv/touchfile
+ ./.venv/bin/python web-project/src/solo_tool_web.py
+
+cli: .venv/touchfile
+ ./.venv/bin/solo-tool-cli https://files.0xf7.com amboss
+
+install: deployment/solo-tool.service deployment/start-solo-tool.sh
+ mkdir -p ~/.config/systemd/user
+ install -o eddy -g eddy -m 644 deployment/solo-tool.service ~/.config/systemd/user
+ chmod 755 deployment/start-solo-tool.sh
+ echo "g_midi" | sudo tee /etc/modules-load.d/solotool.conf
+ echo "options g_midi iProduct=apollo" | sudo tee /etc/modprobe.d/solotool.conf
+ sudo modprobe g_midi iProduct=apollo
+ systemctl --user daemon-reload
+ systemctl --user enable solo-tool.service
+ systemctl --user restart solo-tool.service
+
+uninstall:
+ sudo rm -f /etc/modules-load.d/solotool.conf /etc/modprobe.d/solotool.conf
+ systemctl --user disable --now solo-tool.service
+ rm -f ~/.config/systemd/user/solo-tool.service
+ systemctl --user daemon-reload
+
+.PHONY: all test clean web-deploy web-dev cli install uninstall