updated makefile

This commit is contained in:
locker98 2024-12-16 09:59:30 -05:00
parent b8fed4fb23
commit 77126a8dc6
2 changed files with 10 additions and 9 deletions

2
.gitignore vendored
View File

@ -2,7 +2,7 @@
__pycache__/ __pycache__/
*.py[cod] *.py[cod]
*$py.class *$py.class
logfile
# C extensions # C extensions
*.so *.so

View File

@ -1,11 +1,12 @@
BRANCH ?= main BRANCH ?= main
update_and_build: update_and_build:
@git fetch @git fetch
@if [ "`git rev-list HEAD...origin/$(BRANCH) --count`" -ne "0" ]; then \ @if [ "`git rev-list HEAD...origin/$(BRANCH) --count`" -ne "0" ]; then \
echo "Updates found. Pulling changes and building..."; \ echo "Updates found. Pulling changes and building..."; \
git pull; \ git pull; \
docker run --rm -it -v ${PWD}:/docs squidfunk/mkdocs-material build; \ docker run --rm -it -v ${PWD}:/docs squidfunk/mkdocs-material build; \
else \ else \
echo "No updates. Skipping build."; \ echo "No updates. Skipping build."; \
fi fi