diff options
author | eug-vs <eug-vs@keemail.me> | 2021-07-14 18:47:00 +0300 |
---|---|---|
committer | eug-vs <eug-vs@keemail.me> | 2021-07-14 18:47:00 +0300 |
commit | c3978bdd56844992630221f23dd3cbe66e3d0088 (patch) | |
tree | aea809994cb334bb38309925cd20f044a2af5b1d | |
parent | 016716faf2462ced216aeda1d79815f24d6008fc (diff) | |
download | eug-vs-xyz-c3978bdd56844992630221f23dd3cbe66e3d0088.tar.gz |
feat: inject recent blog-posts into homepage
-rw-r--r-- | .gitignore | 1 | ||||
-rw-r--r-- | Makefile | 10 | ||||
-rwxr-xr-x | index.md | 3 |
3 files changed, 13 insertions, 1 deletions
@@ -1 +1,2 @@ *.html +blog/preview.md @@ -21,6 +21,14 @@ all: $(HTML) @echo $@ @sed "$(LINK_SEDSTRING) $(EMOJI_SEDSTRING)" $< | pandoc $(PANDOC_ARGS) > $@ +index.html: index.md blog/preview.md + @echo $@ + @sed "/Recent blog posts/r blog/preview.md" $< | sed "$(LINK_SEDSTRING) $(EMOJI_SEDSTRING)" | pandoc $(PANDOC_ARGS) > $@ + +blog/preview.md: blog/index.md + @echo $@ + @sed -n "s/^-/ -/; /^ -/p" $< | head -n 4 > $@ + open: $(HTML) $(BROWSER) index.html @@ -28,5 +36,5 @@ deploy: $(HTML) rsync -zarv --exclude=".git" --exclude="*.md" . $(RSYNC_DESTINATION) clean: - rm -f $(HTML) + rm -f $(HTML) blog/preview.md @@ -9,6 +9,9 @@ This website runs on my local *Raspberry Pi* and features secure **HTTPS** conne No bullshit, ads, trackers or client-side JavaScript here. +# Recent blog posts + - [See all...](./blog/index.md) + # Articles :page_with_curl: - [TaskWarrior is all you need to be productive! :taskwarrior:](taskwarrior.md) |