Yass

Yet Another Static Site (generator)
(17/03/2021)
Repo: https://github.com/bomboclat/yass

Yass is a static site generator that I've written to build this website. It's like a glue written in shellscript (~90 lines of code) between sfi that import various website pieces (menu, footer, content, etc...) and smu that compile Markdown-like syntax to HTML.

Index

Features

Dependencies

The only dependencies are: sh(1), find(1), dirname(1), sed(1), sfi, smu. Both sfi and smu required only a C compiler to build and make (optional), the others deps (sh, find, dirname and sed) are standard unix utilities.

HOW-TO

This tutorial explains how to build a website using Yass. To follow this how-to, you need git and a C compiler already installed in your system.

For this tutorial, I will also use the "quick and dirty" step in the README.md.

Build a website

IMPORTANT!: You should use the flag --recursive to clone all repo submodules. Or you can run the command git submodule init && git submodule update in the cloned repository.

Yass places the compiled website in the ./build directory by default. You can test it with any web server. For example, to test the website I use the python3 default web server:

python3 -m http.server -d build/ -b 127.0.0.1 8080

Now you can browse your beautiful website at http://localhost:8080 :D
It will be somthing like this

example website

Directory structure

Now let's take a look inside the examples directory

cd examples

You will find a directory structure like this:

.
├── template.html
├── index.md
├── articles
│   ├── template.html
│   ├── index.md
│   └── example.md
├── components
│   ├── banner.html
│   ├── footer.html
│   └── menu.html
├── css
│   ├── components
│   │   ├── banner.css
│   │   ├── content.css
│   │   └── menu.css
│   └── style.css
└── static
    └── nyan.png

You will notice that in the current (.) and articles directories, there are two files: index.md and template.html.

The examples directory contains also 3 sub-directories:

Back to menu