Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/jwoudenberg/jay
a static site generator written for Roc
https://github.com/jwoudenberg/jay
Last synced: about 2 months ago
JSON representation
a static site generator written for Roc
- Host: GitHub
- URL: https://github.com/jwoudenberg/jay
- Owner: jwoudenberg
- License: gpl-3.0
- Created: 2024-10-13T17:37:25.000Z (3 months ago)
- Default Branch: main
- Last Pushed: 2024-11-05T21:07:45.000Z (about 2 months ago)
- Last Synced: 2024-11-05T21:29:25.680Z (about 2 months ago)
- Language: Roc
- Homepage:
- Size: 310 KB
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Jay - a static site generator for Roc
**IMPORTANT: this project is not nearly done yet! The README below is aspirational!**
Jay takes a directory of files and turns it into a website.
Let's say you have the following source files:```
index.md
blog.md
posts/
a-great-day.md
static/
image.jpg
style.css
build.roc
```Jay will turn those markdown files into HTML and produce a site with the following paths:
```
/index.html
/blog.html
/posts/a-great-day.html
/static/image.jpg
/static/style.css
```You define the markdown conversion and any other transformations in build.roc.
## Getting started
In a directory with some source files, create a file `build.roc` with the following contents:
```roc
#!/usr/bin/env roc
app [main] { pf: platform "github.com/jwoudenberg/roc-static-site" }import Pages
main = Pages.bootstrap
```The shebang on the first line makes it a script. Run it by typing `./build.roc`. This will:
- Replace `build.roc` with a draft site generation script that you can customize.
- Build an initial version of the site and serve it on a local port.
- Rebuild the site if you make changes to build.roc or source files.