Chercan Static Site Generator
A simple static site generator using Wren programming language.
Just Wren CLI is needed. (Although Python3 is used for local server mode.).
-
Installation:
-
MacOS:
make wren-macos
-
Linux:
make wren-linux
.
├── LICENSE
├── Makefile
├── README.adoc
├── chercan
│ ├── build.wren
│ └── config.wren
├── content
│ ├── hello
│ │ ├── hello.adoc
│ │ └── hello.html
│ ├── hello.wren
│ └── index.wren
├── docs
│ ├── hello.html
│ ├── index.html
│ ├── normalize.css
│ └── sakura-vader.css
├── static
│ ├── normalize.css
│ └── sakura-vader.css
├── themes
│ └── default
│ ├── default.wren.html
│ ├── home.wren.html
│ └── partials
│ ├── footer.wren.html
│ └── header.wren.html
└── wren
└── run
Create your files inside content
. Only root level *.wren
files supported for now (Wren CLI limitations).
-
./run new <name>
: It will create a new wren file insidecontent
. -
./run new:adoc <name>
: It will create a new filename with its *.wren and *.adoc insidecontent
. -
./run build
: It will executemake build
. (Builds wren files). -
./run build:adoc
: It would only build asciidoc files. (Requires AsciiDoctor). -
./run build:all
: It will executemake build-all
(Builds wren and asciidoc files). -
./run serve
: It will executemake serve
. (Requires Python3).
You could also create a directory with Asciidoc files and use the html output to append it to the file contents. It must have the same name as the Wren file.
-
Example Page:
class Page {
static title {"Hello Chercan"}
static content {Asciidoc.read()}
}
return Page
You can create your own themes. They are just Wren files
that uses Wren tags <?wren ?>
. You have all the Wren power
in these templates.
Name them as <name>.wren.html
. Configure the default theme in chercan/config.wren
.
Made with ♥ by Ninjas.cl .