- C 99.7%
- HTML 0.3%
| Filename | Latest commit message | Latest commit date |
|---|---|---|
| example | ||
| src | ||
| .gitignore | ||
| config.h | ||
| LICENSE | ||
| nob.c | ||
| nob.h | ||
| README.md | ||
zettp-kani
Kani is a static site generator, written in C
Good:
- Fast
- <1mb executable
- Written in c
Bad:
- Written in c
Requirements
- Linux system
- c compiler with gnu23 support ( gcc >= 14.2 )
If you prefer musl over glibc, in nob.c, uncomment the line from the top.
Why not c99 like every reasonable person would use?
Because we are not in 1999 anymore.
Note
No testing done for Windows or Mac
Supported markdown features
Supported:
- Headers
- Paragraphs
- Metadata block including "Top image" for a "post"
- Unordered lists (-ul blocks)
- Ordered lists (-ol blocks)
TODO:
- Images
Usage
[1]
To use Kani, first you need to configure it using config.h
Give it the list of .md files you want to convert and also the output path.
[2] Bootstapping build system. in the root folder:
gcc -static nob.c -o nob
./nob
[3] Running Kani
./build/kani
By default, Kani doesnt overwrite files, if you want to trigger re generation of all .html files,
use -f or --force flag:
./build/kani -f
The generated .html files are inside the public_folder you defined in config.h
Credits
nob.h: https://github.com/tsoding/nob.h
stb_ds.h: https://github.com/nothings/stb