No description
Find a file
2019-12-01 21:24:56 -08:00
bin Make the site generator recursively render public files 2019-12-01 15:43:49 -08:00
images new favicon 2014-03-02 15:58:36 -08:00
public WIP: Render known pages and get template in place 2019-12-01 21:08:21 -08:00
SiteGenerator WIP: Simplify by removing known pages for now 2019-12-01 21:24:56 -08:00
templates WIP: Render known pages and get template in place 2019-12-01 21:08:21 -08:00
Tests WIP: Render known pages and get template in place 2019-12-01 21:08:21 -08:00
wayback wat? 2014-04-06 22:14:56 -07:00
.gitignore remove sitegen binary 2019-12-01 14:45:56 -08:00
.tm_properties Add support for rendering CSS from Less 2019-12-01 16:51:51 -08:00
Gemfile Exorcise harp and node.js, server, and add Swift plan 2019-12-01 10:59:05 -08:00
Gemfile.lock Exorcise harp and node.js, server, and add Swift plan 2019-12-01 10:59:05 -08:00
Makefile Make the site generator render index.html with a layout 2019-12-01 14:44:06 -08:00
Readme.md WIP: Render known pages and get template in place 2019-12-01 21:08:21 -08:00
site.json WIP: Render known pages and get template in place 2019-12-01 21:08:21 -08:00

samhuri.net

The source code for samhuri.net.

New version using Swift

The idea is to create a bespoke set of tools, not a general thing like Jekyll. If something can be factored out later that's a bonus, not a goal.

This is a plan for migrating from a mix of node.js (harp) and Ruby to Swift. Use Ink, John Sundell's Markdown parser, to render posts, and some other library for generating HTML. Will probably try generating HTML from code because I've never tried it and it seems fun. The pointfree.com guys have one already and Sundell is releasing one Real Soon(tm).

This version will go back to its roots and use headers at the top of markdown files. It was so much easier than indexing everything. Check out the old repo to see how nice it was back in the day. The code that renders it was separate and is available at 9af9d75.

Execution, trying TDD for the first time:

  • Replace harp with custom Swift code

    • Write a test harness that renders a site and then checks the output with diff -r

    • Write a site generator that renders www/index.html from site.json

    • Add support for site styles

    • Add support for page styles

    • Add support for site scripts

    • Add support for page scripts

    • Add support for CSS files

    • Transform LESS into CSS

    • Migrate projects to the new site generator

    • Migrate posts to markdown with headers somehow

      • Define the new format, probably with a folder for each year of posts since I don't write very much

      • Decide whether to migrate from 9af9d75 or the current harp format (probably easier to migrate the new format because posts may have been updated since then)

      • Migrate posts

  • Add a link to the code for samhuri.net somewhere ... so meta (about page?)

  • Generate RSS feed (ditch mustache templates)

  • Generate JSON feed

  • Munge HTML files to make them available without an extension (index.html hack)

  • Inline CSS?

  • Minify JS

  • Add a server for local use and simple production setups

  • Figure out an iPad workflow with minimal code. Maybe a small app with some extensions and shortcuts?