diff options
author | Sylvain Gauthier <s94.gauthier@laposte.net> | 2021-01-17 12:35:37 +1100 |
---|---|---|
committer | Sylvain Gauthier <s94.gauthier@laposte.net> | 2021-01-17 12:35:37 +1100 |
commit | b630934434dd9f38a4652e73376fa9781da5a291 (patch) | |
tree | 63db4ff22ba302ec6b72404b12c0e09a3225fb3b | |
parent | 733c3118866e18ed1c92f5dabc938434fcfa6647 (diff) |
add AUTHOR variable for article pages
-rwxr-xr-x | blogit | 2 |
1 files changed, 2 insertions, 0 deletions
@@ -130,6 +130,8 @@ blog/%.html: articles/% $(addprefix templates/,$(addsuffix .html,header article_ mkdir -p blog TITLE="$(shell head -n1 $<)"; \ export TITLE; \ + AUTHOR="$(shell git log -n 1 --reverse --format="%cn" -- "$<")"; \ + export AUTHOR; \ DATE_POSTED="$(shell git log --diff-filter=A --date="format:$(BLOG_DATE_FORMAT)" --pretty=format:'%ad' -- "$<")"; \ export DATE_POSTED; \ DATE_EDITED="$(shell git log -n 1 --date="format:$(BLOG_DATE_FORMAT)" --pretty=format:'%ad' -- "$<")"; \ |