Added blog

This commit is contained in:
j4nk 2023-03-26 22:16:24 -04:00
parent 60d8650d98
commit 709d5f0c2a
4 changed files with 41 additions and 2 deletions

View File

@ -1,5 +1,5 @@
PARSEFUNC=md4tj-parse
CC=emacs --no-site-file --batch -l ./md4tj/md4tj.el --eval
CC=emacs --no-site-file --batch -l ./md4tj/md4tj-util.el -l ./md4tj/md4tj.el -l ./md4tj/md4tj-blog.el --eval
.PHONY: css
#.PHONY: vids
@ -8,7 +8,12 @@ SITE_ROOT=./site_root
# Makes sure the necessary destination directories get made
SITE_ROOT_RESULT=$(shell sh make_site_root.sh)
all: $(SITE_ROOT_RESULT) index about links archives takes restaurants css
BLOGS=$(wildcard ./blog/*.md4tj)
BLOGSHTMLTMP=$(addprefix $(SITE_ROOT)/,$(BLOGS))
BLOGSHTML=$(subst .md4tj,.html,$(BLOGSHTMLTMP))
#$(error $(BLOGSHTML))
all: $(SITE_ROOT_RESULT) index about links archives takes restaurants css blog
index: $(SITE_ROOT)/index.html
@ -22,9 +27,14 @@ archives: $(SITE_ROOT)/archives.html
restaurants: $(SITE_ROOT)/restaurants.html
blog: $(SITE_ROOT)/blog.html $(BLOGSHTML)
$(SITE_ROOT)/%.html: %.md4tj
$(CC) "($(PARSEFUNC) \"$^\" \"$@\")"
$(SITE_ROOT)/blog/%.html: %.md4tj
$(CC) "($(PARSEFUNC) \"$^\" \"$@\")"
css:
cp css/main.css site_root/css

14
blog.md4tj Normal file
View File

@ -0,0 +1,14 @@
@@META charset UTF-8
@@META name viewport content width=device-width,initial-scale=1.0
@@TITLE The Jerks - Blog
@@CSS css/main.css
# The Jerks
## Blog
My mindless ramblings.
@@INCLUDE nav.md4tj
@@BLOGBASEDIR ./blog/
@@BLOGBASEURL https://www.thejerks.club/blog/
@@BLOGINSERT

14
blog/helloworld.md4tj Normal file
View File

@ -0,0 +1,14 @@
@@META charset UTF-8
@@META name viewport content width=device-width,initial-scale=1.0
@@TITLE Hello world!
@@CSS ../css/main.css
# The Jerks
## Blog
### Hello world!
@@INCLUDE nav.md4tj
@@BLOGPOSTTITLE Hello world!
@@BLOGPOSTDATE 1679880579
Hello world! This is my first blog post. Not much to see here, this is mainly a test to make sure my blog generates properly. More blog posts forthcoming.

View File

@ -2,3 +2,4 @@
mkdir -p ./site_root
mkdir -p ./site_root/css
mkdir -p ./site_root/vids
mkdir -p ./site_root/blog