This is the Rust implementation of Shonku project.
This is kind of stable, I am using it for long enough now for my blog.
rustup default nightly
cargo build --features shadow --release
The shadow
feature will enable -e/--exe
to get details about the executable.
But, in case you want to run it under WASI, then build it using the following command.
cargo build --target wasm32-wasi --release
You will the following directory structure.
|-> templates
|-> pages
|-> posts
|-> output
|
|-> posts
|-> pages
|-> categories
|-> assets
You can make them all as
mkdir -p pages posts output/{posts,pages,categories}
cp -r assets output/
cp ./target/wasm32-wasi/release/khata.wasm ./
wasmtime --dir=. khata.wasm -- -h
./khata --new
wasmtime --dir=. khata.wasm -- --new
./khata
wasmtime --dir=. khata.wasm
To build the updated/new posts.
./khata --rebuild
wasmtime --dir=. khata.wasm -- --rebuild
To rebuild the whole site.
./khata -h
wasmtime --dir=. khata.wasm -- -h
To view all the help options.
We have default templates and assets in the git repo.
./khata -e