Cryogen

Static sites generated with Clojure

A basic Cryogen site usually looks something like this: (New files may be added in the future)

my-blog
├── resources
│   ├── public
│   │   ⋮
│   └── templates
│       ├── asc
│       │   ├── pages
│       │   │   └── adoc-page.asc
│       │   └── posts
│       │       └── 2014-10-10-adoc-post.asc
│       ├── md
│       │   ├── pages
│       │   │   ├── about.md
│       │   │   └── another-page.md
│       │   └── posts
│       │       ├── 2014-03-10-first-post.md
│       │       ├── 2014-11-04-second-post.md
│       │       └── 2014-12-11-docs.md
│       ├── img
│       ├── themes
│       │   ├── blue
│       │   │   ├── css
│       │   │   │   └── screen.css
│       │   │   ├── html
│       │   │   │   ├── 404.html
│       │   │   │   ├── archives.html
│       │   │   │   ├── base.html
│       │   │   │   ├── home.html
│       │   │   │   ├── page.html
│       │   │   │   ├── post-content.html
│       │   │   │   ├── post.html
│       │   │   │   ├── previews.html
│       │   │   │   ├── tag.html
│       │   │   │   └── tags.html
│       │   │   └── js
│       │   │       └── highlight.pack.js
│       │   └── blue_centered
│       │       ⋮
│       ├── config.edn
├── src
│   └── cryogen
│       ├── core.clj
│       └── server.clj       
└── project.clj

File/Dir Description
resources This is where all of your site content and configuration will go. It's divided into the templates folder and the public folder.
public This is where the generated site will go once Cryogen is done compiling your content.
templates The main folder where all your HTML themes and Markdown/AsciiDoc content will go.
asc If you are using AsciiDoc then keep your content here.
md If you are using Markdown then keep your content here.
pages The root folder for all your custom Markdown/Asciidoc pages. This folder name can be changed in config.edn.
posts The root folder for all your post content in Markdown/Asciidoc. This folder name can also be changed.
img The default directory to place images.
themes This directory contains themes that you may apply to your site. You may use a theme by specifying its name under the theme key in config.edn.
themes/{theme}/css Pretty self explanatory. Put your theme's css files here
themes/{theme}/html These are the templates that wrap posts and pages. Layouts are selected on a post-by-post basis and content gets injected by Selmer.
themes/{theme}/js Also self explanatory. The theme's JavaScript files go here.
config.edn Configuration data for your site.
src/cryogen Contains the core and server.
project.clj Your typical project file for a Clojure project.

The html templates use Selmer which can extend other templates. Most html templates extend off of base.html. The following diagram gives an overview of the Cryogen Selmer hierachy.

Selmer Hierachy

Markdown/AsciiDoc content is injected into their specified layout files and then injected into the base html layout to create each page of your site.