summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authoreug-vs <eug-vs@keemail.me>2021-07-03 19:55:35 +0300
committereug-vs <eug-vs@keemail.me>2021-07-03 19:58:21 +0300
commit1fe8ed053778ea63a5bfc6efb96f3c8bab449554 (patch)
tree310bf6795259fbc9ecba1efe1f94d7a6c55ad526
parent317c9b42081aa033abd7b46f05f47428f2942ae7 (diff)
downloadeug-vs-xyz-1fe8ed053778ea63a5bfc6efb96f3c8bab449554.tar.gz
chore: add open make target
-rw-r--r--Makefile6
-rwxr-xr-xcompile_emoji_sedstring.sh2
2 files changed, 6 insertions, 2 deletions
diff --git a/Makefile b/Makefile
index 7a64cdc..359c8a3 100644
--- a/Makefile
+++ b/Makefile
@@ -1,4 +1,5 @@
RSYNC_DESTINATION=root@eug-vs.xyz:/var/www/website
+BROWSER=brave
MARKDOWN=gfm+emoji
STYLESHEET=/style.css
@@ -18,7 +19,10 @@ all: $(HTML)
%.html: %.md
@echo $@
- @cat $< | sed "$(LINK_SEDSTRING) $(EMOJI_SEDSTRING)" | pandoc $(PANDOC_ARGS) > $@
+ @sed "$(LINK_SEDSTRING) $(EMOJI_SEDSTRING)" $< | pandoc $(PANDOC_ARGS) > $@
+
+open: $(HTML)
+ $(BROWSER) index.html
deploy: $(HTML)
rsync -zarv --exclude=".git" --exclude="*.md" . $(RSYNC_DESTINATION)
diff --git a/compile_emoji_sedstring.sh b/compile_emoji_sedstring.sh
index 2a71715..ef22247 100755
--- a/compile_emoji_sedstring.sh
+++ b/compile_emoji_sedstring.sh
@@ -3,5 +3,5 @@ cd public/emoji;
for EMOJI in *;
do
BASENAME=${EMOJI%.*}
- echo "s|:${BASENAME}:|<img src=\\\"/public/emoji/${EMOJI}\\\" height=\\\"24px\\\" style=\\\"margin-bottom: -4px\\\">|g; "
+ echo "s|:${BASENAME}:|<img src=\\\"public/emoji/${EMOJI}\\\" height=\\\"24px\\\" style=\\\"margin-bottom: -4px\\\">|g; "
done