# markdown sources
posts=$(patsubst %.md,build/%.html,$(wildcard blog/*.md))
# static sources
-S=index.html img/
+S=img/
-all: blog $S $(posts)
+all: build/index.html blog $S
cp -av $S build/
-blog: build/blog/
+blog: build/blog/ $(posts)
build/:
mkdir -p $@
build/blog/: build/
mkdir -p $@
-build/blog/%.html: blog/%.md build/
+build/index.html: index.md build/ inc/head.template inc/foot.template
+ sed "s/__TITLE__/thefekete.net/; /__DATE__/d" inc/head.template >$@
+ markdown index.md >>$@
+ cat inc/foot.template >>$@
+
+build/blog/%.html: blog/%.md build/ inc/head.template inc/foot.template
@# `pacman -S discount` for `markdown`
bin/blog.awk $< >$@
<a href="https://thingiverse.com/thefekete">Thingiverse</a>
</nav>
<div style="clear: both"></div>
- <p style="float: right"><small>__DATE__</small></p>
- <div style="clear: both"></div>
+ <p style="float: right"><small>__DATE__</small></p><div style="clear: both"></div> <!-- one line so we can delete it if we want -->
<h1>__TITLE__</h1>
</header>
+++ /dev/null
-<!DOCTYPE html>
-<html lang="en">
- <head>
- <meta charset="utf-8">
- <title>thefekete.net</title>
- <!-- <link rel="stylesheet" href="style.css"> -->
- <!-- <script src="script.js"></script> -->
- </head>
- <body>
- <nav style="float: right">
- <a href="https://thefekete.net">thefekete.net</a> |
- <a href="https://thefekete.net/blog">Blog</a> |
- <a href="https://git.thefekete.net">Git</a> |
- <a href="https://www.youtube.com/user/thefekete">YouTube</a> |
- <a href="https://gitlab.com/thefekete">GitLab</a> |
- <a href="https://github.com/thefekete">GitHub</a> |
- <a href="https://thingiverse.com/thefekete">Thingiverse</a>
- </nav>
- <div style="clear: both"></div>
-
- <h1>thefekete.net</h1>
- <img src="img/trogdor.png" alt="The burninator" />
- <p>This is the first sentence.</p>
- <p><small>
- Special thanks to <a href="http://lukesmith.xyz">Luke Smith</a> for the
- last little kick to finally get my site back up after more than
- <a href="https://web.archive.org/web/20121029100909/http://thefekete.net/">
- 8 years of down time
- </a>.
- </small></p>
- </body>
-</html>
\ No newline at end of file
--- /dev/null
+
+
+This is the first sentence.
+
+Special thanks to [Luke Smith](http://lukesmith.xyz) for the
+last little kick to finally get my site back up after more than
+[8 years of down time](https://web.archive.org/web/20121029100909/http://thefekete.net/)