Yet Another Micro Blog.
Static site generator for micro blogs. Heavily inspired by WorstPress.
Want a preview? Check out my blog.
- Pandoc
- Write your first Markdown entry in
entries/recent
directory. - Run
compile.sh
script. - Serve
www
directory.
About
page will be generated fromtemplates/about.md
file.- The name of the Markdown file will be used as the title of the blog entry.
- Category of the blog entry is determinted by the folder name of the Markdown file.
- If you have an idea for a blog entry place it in the
entries/soon
folder. - If you are working on a blog entry place it in the
entries/current
folder. - If you are done with it, move it to
entries/recent
folder. - For standalone, non-entry pages, place them in
entries/standalone
folder. - If you any media files, place them in
entries/media
folder. - First line of the Markdown file will be used as the date of the blog entry and recent entries will be sorted alphabetially according to this date.
- You can setup
cron
for runningcompile.sh
andrsync
commands which will generate HTMLs and copy them to a remote server periodically. Voilà! You don't even have to think about the boring stuff. An example cron file is also provided. - I use
<sub><sup>DATE</sup></sub>
format for the first line of my entries so that the date is small and neat. - Want to use LaTeX equations in your blog? Check out this blog post. YAMB will not automatically add MathJax to your pages so it doesn't load on every page.
- The insertion of generated
HTML
files in templates is dependant on the line which we are trying to insert. This can be done without usingsed -i "50r ./tmp/archive.html" ./www/archive.html
. (done in 2241690) -
Recent
section should include only 10 most recent entries. For now it's handled by checking the line count of the generated HTML, which is not ideal. (done in 7ec715a) -
Current
section includes entries based on_
prefix of the Markdown file, also not good. (done in fce9acc) - Generate pages that are not shown as entries, but standalone articles.
books.html
,podcasts.html
, etc. -
ls -t
andstat
commands are not ideal since it sorts by modification time, not creation time.--time=birth
is not available on all filesystems. Sorting the files based on the first line of the file which will include the desired date is a better solution. If date not present, take modification time. (done in 6ee1ec4) - Pages with not enough text to fill the full width of the
body
appear to be more narrow than the rest. (done in 6ee1ec4) -
Current
andSoon
sections be displayed only if there are entries in them. (done in ccc7b47) - Better handling of temporary files for reability.
- RSS. (Wohoo! done in 55d7893)