add makefile

master
Dirk Heilig 2024-01-18 14:33:52 +01:00
parent e18582f9b4
commit 8fd74be9be
2 changed files with 23 additions and 0 deletions

1
.gitignore vendored
View File

@ -11,3 +11,4 @@ hugo.linux
# Temporary lock file while building
/.hugo_build.lock
dist

22
Makefile 100644
View File

@ -0,0 +1,22 @@
.PHONY: build minify clean release deploy_test
release: build minify
build: clean
hugo --gc --minify --cleanDestinationDir
clean:
rm -rf public dist
minify: dist build
minify -a -r -o dist/ public/. -q --exclude "public/js/jquery-3.7.1.min.js"
cp -rp public/js/jquery-3.7.1.min.js dist/public/js/jquery-3.7.1.min.js
mv dist/public/* dist/
rm -rf dist/public
dist:
mkdir dist
deploy_test: release
rsync -rv --delete dist/* shnbk.de:domains/c3retest.shnbk.de/htdocs