Browse Source

add check for git status

main
mm 2 years ago
parent
commit
282c0466d8
  1. 16
      Makefile

16
Makefile

@ -1,16 +1,20 @@
city_distances.csv: lint generate_data.py city_distances.csv: check generate_data.py
bash -c 'time python generate_data.py' bash -c 'time python generate_data.py'
train: check train.py
bash -c 'time python train.py'
eval: check eval.py
bash -c 'time python eval.py'
lint: lint:
isort --profile=black . isort --profile=black .
black . black .
flake8 --max-line-length=88 . flake8 --max-line-length=88 .
train: lint train.py check: lint
bash -c 'time python train.py' @echo "Checking for unstaged or untracked changes..."
@git diff-index --quiet HEAD -- || { echo "Unstaged or untracked changes detected!"; exit 1; }
eval: lint eval.py
bash -c 'time python eval.py'
clean: clean:
rm -rf output/ rm -rf output/

Loading…
Cancel
Save