diff --git a/Makefile b/Makefile index 9b9508b..2421b1c 100644 --- a/Makefile +++ b/Makefile @@ -1,11 +1,14 @@ all: run run: - nohup .venv/bin/python app.py > output.log 2>&1 & echo $! > app.pid + nohup python app.py > output.log 2>&1 & echo $$! > app.pid stop: - kill -9 $(cat app.pid) || true - rm -f app.pid + @if [ -s app.pid ]; then \ + kill -9 $$(cat app.pid) && rm -f app.pid; \ + else \ + echo "No running process found."; \ + fi restart: stop run @@ -13,5 +16,4 @@ logs: tail -f output.log clean: stop - rm -f output.log - + rm -f output.log app.pid diff --git a/output.log b/output.log deleted file mode 100644 index e69de29..0000000