2015-01-11 21:52:17 +00:00
|
|
|
all: compile compress upload
|
|
|
|
|
|
|
|
compile: clean
|
|
|
|
@echo "=== Generating static files"
|
|
|
|
@bundle exec jekyll build
|
|
|
|
@echo "Done."
|
|
|
|
|
2016-02-29 21:40:06 +00:00
|
|
|
compress: compile
|
2015-01-11 21:52:17 +00:00
|
|
|
@echo "=== Compressing generated files"
|
2015-01-31 17:58:08 +00:00
|
|
|
@find ./_site -type f | xargs zopfli --gzip --i30
|
2018-05-09 20:03:19 +00:00
|
|
|
@find ./_site -type f ! -name "*.gz" | xargs -I {} brotli --quality=11 --output={}.br {}
|
2016-02-29 21:40:06 +00:00
|
|
|
@find ./_site -type f -name "*.br" | xargs chmod 644
|
2015-01-11 21:52:17 +00:00
|
|
|
@echo "Done."
|
|
|
|
|
|
|
|
upload:
|
|
|
|
@echo "=== Syncing files"
|
2018-05-09 20:03:19 +00:00
|
|
|
@rsync --rsync-path="sudo rsync" -avz --no-o --no-g -e ssh --chmod=og=r -p --delete _site/ kempkens.io:/iocage/jails/webserver/root/var/www/main
|
2015-01-11 21:52:17 +00:00
|
|
|
@echo "Done."
|
|
|
|
@echo "=== Changing permissions"
|
2018-05-09 20:03:19 +00:00
|
|
|
@ssh kempkens.io sudo /usr/home/daniel/bin/chmodweb /iocage/jails/webserver/root/var/www/main
|
2015-01-11 21:52:17 +00:00
|
|
|
@echo "Done."
|
|
|
|
|
|
|
|
clean:
|
|
|
|
@rm -rf ./_site
|