From 213f8c2ce1d6c27bf579e7cb440e6ff53f076d30 Mon Sep 17 00:00:00 2001 From: Volpeon Date: Wed, 23 Dec 2020 17:57:36 +0100 Subject: Added favicon, also watch templates folder --- Makefile | 5 ++++- content/favicon.ico | Bin 0 -> 7406 bytes scripts/build_content.sh | 2 +- scripts/watch_templates.sh | 7 +++++++ templates/base.html | 3 ++- 5 files changed, 14 insertions(+), 3 deletions(-) create mode 100644 content/favicon.ico create mode 100755 scripts/watch_templates.sh diff --git a/Makefile b/Makefile index 03ef22a..ced1bda 100644 --- a/Makefile +++ b/Makefile @@ -31,7 +31,10 @@ watch_sass: build watch_content: build @scripts/watch_content.sh -watch: watch_sass watch_content +watch_templates: build + @scripts/watch_templates.sh + +watch: watch_sass watch_content watch_templates serve_only: build @python -m http.server --bind 127.0.0.1 --directory output diff --git a/content/favicon.ico b/content/favicon.ico new file mode 100644 index 0000000..39895e5 Binary files /dev/null and b/content/favicon.ico differ diff --git a/scripts/build_content.sh b/scripts/build_content.sh index 460a3fe..0698ee0 100755 --- a/scripts/build_content.sh +++ b/scripts/build_content.sh @@ -39,7 +39,7 @@ if [ -z "$1" ]; then done elif [ "$2" = "delete" ]; then TARGET=$(target "$1") - echo "[DELETE] $1 -> $TARGET" + echo "[DELETE ] $1 -> $TARGET" rm -rf $TARGET else handle "$1" diff --git a/scripts/watch_templates.sh b/scripts/watch_templates.sh new file mode 100755 index 0000000..160a46c --- /dev/null +++ b/scripts/watch_templates.sh @@ -0,0 +1,7 @@ +#!/bin/bash + +inotifywait -qrme close_write,delete,move --format "%w%f" templates \ + | while read FILENAME + do + scripts/build_content.sh + done diff --git a/templates/base.html b/templates/base.html index a4d81ba..25232dc 100644 --- a/templates/base.html +++ b/templates/base.html @@ -4,7 +4,8 @@ - + + $for(author-meta)$ $endfor$ -- cgit v1.2.3-54-g00ecf