Static Site generator for generating blogs in Chicken Scheme
chicken-install spiffy lowdown sxml-transforms uuid simple-md5 srfi-19 srfi-13 atom
Use the chicken compiler to create the static wing binary.
csc wing.scm -static
wing init wing new wing publish wing revert wing build
To initialize a project run
wing init in a new directory.
init - Will prompt some questions to fill in config file fields.
new - Will prompt some questions to fill in post fields.
publish - Will list out any unpublished posts, and prompt for the user to select one.
revert - Will remove the head (most recent) of the published posts list in posts.scm.
build - This will read the newly generated
posts.scm file and generate html and an atom.xml file from the meta data and file contents.
Use a file server to preview the built content in the static directory. Using sfz for example:
Which will prompt you for the title, description, and tags. Dates are handled for you.
This will generate a markdown file in the posts directory.
Your post will look something like this:
title: hello world summary: Saying hello to the world tags: hello world blogging ---
The filename will be: hello-world.md
To have multiline code blocks make sure to use 4 spaces on each line of code. Or else lowdown will put all lines of code on one line...
The date format used throughout wing is the RFC3339. The chicken scheme template string looks like this:
wing uses a function called current-rfc3339-date to generate a string looking like this:
wing uses a simple but powerful way to track updates of posts. The center piece of this design is the posts.scm file.
The most important thing to know about this file is don't touch this file!!!
This file looks like this:
(((title "") (summary "") (tags ("foo" "bar")) (path "") (id "") (md5 "") (published "") ;; RFC3339 date (updated ""))) ;; RFC3339 date
When build is run after any updates wing will adjust the updated date field and provide the new md5 hash field. This means there is no manual date effort on the author's part.
The config.scm file is generated by using the values provided in the initial prompt.
The most important thing to know about this file is don't touch this file!
((author "fancycade") (email "firstname.lastname@example.org") (description "") (domain "") (id ""))
wing: Simple Static Site generator for Chicken Scheme Copyright (C) 2020 email@example.com
This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.
This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
You should have received a copy of the GNU General Public License along with this program. If not, see https://www.gnu.org/licenses/.