From 8c9b43ea5f9f10f71b108864229ee026a9de04f6 Mon Sep 17 00:00:00 2001 From: Jordan Robinson Date: Tue, 13 Jan 2026 22:43:48 +0000 Subject: [PATCH] initial commit --- README.md | 110 +++++++++++ index.html | 464 ++++++++++++++++++++++++++++++++++++++++++++ index.md | 22 +++ manifest.json | 4 + nav.json | 9 + posts/manifest.json | 4 + posts/post-1.md | 26 +++ posts/post-2.md | 21 ++ 8 files changed, 660 insertions(+) create mode 100644 README.md create mode 100644 index.html create mode 100644 index.md create mode 100644 manifest.json create mode 100644 nav.json create mode 100644 posts/manifest.json create mode 100644 posts/post-1.md create mode 100644 posts/post-2.md diff --git a/README.md b/README.md new file mode 100644 index 0000000000000000000000000000000000000000..52b29b61fd4c24642829c8adc28fd85ff92b40ff --- /dev/null +++ b/README.md @@ -0,0 +1,110 @@ +# quillhut-static + +A minimalist, client-side static site generator that turns Markdown files into a fast, searchable SPA using vanilla JavaScript and Caddy. + +## Directory Structure + +/opt/www/quillhut-static/ <-- Web Root +├── index.html <-- The engine & layout +├── nav.json <-- Header/Footer links +├── index.md <-- Homepage content +├── rss.xml <-- Generated Feed +├── sitemap.xml <-- Generated Sitemap +├── manifest.json <-- Standalone pages (about, index, etc) +├── posts/ +│ ├── manifest.json <-- List of all post filenames +│ ├── post-1.md <-- Individual post +│ └── post-2.md + +## Setup & Installation + +### 1. Configure Caddy + +Your server must handle "fallback" routing so that if a user refreshes `/posts/my-story`, Caddy knows to serve `index.html`. + +#### Caddyfile Example + +```bash +yourdomain.com { + root * /opt/www/quillhut-static/ + file_server + + # Metadata headers + header /rss.xml Content-Type "application/rss+xml; charset=utf-8" + header /sitemap.xml Content-Type "application/xml; charset=utf-8" + + # SPA Routing + try_files {path} /index.html +} +``` + +### 2. Configure `nav.json` + +```json +{ + "header": [ + { "name": "home", "path": "/" }, + { "name": "posts", "path": "/posts" } + ], + "footer": [ + { "name": "source", "path": "https://sourcehut.org", "external": true } + ] +} +``` + +### 3. Create a Post + +Posts live in `/posts/`. Use YAML-like frontmatter: + +```markdown +--- +title: My First Post +date: 2024-05-22 +tags: tech, web +author: linuxgoose +--- +Post content goes here... +``` + +### 4. Update the Manifest + +Add the filename to `posts/manifest.json`: + +```json +["post-1.md", "post-2.md"] +``` + +## Admin Workflow + +Because this is a static site without a database, robots (like RSS readers or Google) cannot see the content generated by JavaScript. You must manually generate the "static" XML files when you publish new content. +Generating RSS & Sitemap + +1. Open your website in a browser. + +2. Open the Developer Console (`F12` or `Ctrl+Shift+I`). + +3. Type the following command and hit Enter: + +```bash +generateRSS(); generateSitemap(); +``` + +4. Two files (rss.xml and sitemap.xml) will download to your computer. + +5. Upload these files to your server's root directory. + +## Features + +- Zero Build Step: Just upload Markdown and refresh. + +- Tag Filtering: Automatic tag cloud generation from post metadata. + +- Clean URLs: No .html extensions required. (set `USE_CLEAN_PATHS` to *true*) + +- Dark Mode: Automatic support based on system preferences. + +- Lightweight: Powered by marked.js and vanilla JS. + +## License + +Open source under the MIT License. Contributions welcome. \ No newline at end of file diff --git a/index.html b/index.html new file mode 100644 index 0000000000000000000000000000000000000000..8bca63bca5b95ca4e9ece7bb77d44098e6ad2e72 --- /dev/null +++ b/index.html @@ -0,0 +1,464 @@ + + + + + + + quillhut-static + + + + + +
+ +
+ +
+
+ +
+ + + + + + + \ No newline at end of file diff --git a/index.md b/index.md new file mode 100644 index 0000000000000000000000000000000000000000..21b2e0e5027e751610e7be7da5d34228c0f23412 --- /dev/null +++ b/index.md @@ -0,0 +1,22 @@ +# Hello, World! + +Welcome to my personal corner of the web. This site is powered by **quillhut**, a minimalist static site engine that renders Markdown directly in your browser. + +### About this site +This is a boilerplate example of the `index.md` file. It serves as the homepage for the SPA (Single Page Application). + +* **Fast:** No heavy frameworks, just vanilla JS. +* **Markdown-first:** Write in plain text, and it just works. +* **Clean:** No trackers, no ads, just content. + +### Recent Projects +You can find my latest writing in the [posts](/posts) section. I focus on: +1. **Minimalist Web Design** +2. **Linux & Open Source** +3. **Static Site Architectures** + +--- + +> "Simplicity is the ultimate sophistication." — Leonardo da Vinci + +If you want to reach out, feel free to check my [security.txt](/security.txt) for contact details or verify my identity via my [PGP key](/pgp-key.txt). \ No newline at end of file diff --git a/manifest.json b/manifest.json new file mode 100644 index 0000000000000000000000000000000000000000..9db89a4938cd981e68bc66f89bb282f41194f562 --- /dev/null +++ b/manifest.json @@ -0,0 +1,4 @@ +[ + "index.md", + "posts.md" +] \ No newline at end of file diff --git a/nav.json b/nav.json new file mode 100644 index 0000000000000000000000000000000000000000..ec5a0326d564e441e95a84c2907f9b2a8ae53bf1 --- /dev/null +++ b/nav.json @@ -0,0 +1,9 @@ +{ + "header": [ + { "name": "Home", "path": "index" }, + { "name": "Journal", "path": "posts" } + ], + "footer": [ + { "name": "source", "path": "https://sourcehut.org", "external": true } + ] +} \ No newline at end of file diff --git a/posts/manifest.json b/posts/manifest.json new file mode 100644 index 0000000000000000000000000000000000000000..8bdf6167d90b0e4dc50f7b5623a3e600c29f988d --- /dev/null +++ b/posts/manifest.json @@ -0,0 +1,4 @@ +[ +"post-1.md", +"post-2.md" +] \ No newline at end of file diff --git a/posts/post-1.md b/posts/post-1.md new file mode 100644 index 0000000000000000000000000000000000000000..d25d3b6af33c972f407e915da42a5edbf1dc4a7e --- /dev/null +++ b/posts/post-1.md @@ -0,0 +1,26 @@ +--- +title: Why I Built My Own SSG +date: 2026-01-10 +tags: web, javascript, minimalism +author: linuxgoose +--- + +# Why I Built My Own SSG + +I wanted a blog that didn't require a complex build pipeline or a 500MB `node_modules` folder. By using **vanilla JavaScript** and **Caddy**, I created a system where the browser does the heavy lifting. + +### The Technical Stack +- **Engine:** Vanilla JS Router +- **Parser:** [Marked.js](https://marked.js.org/) +- **Server:** Caddy with SPA routing +- **Metadata:** YAML-style frontmatter + +### Code Example +Here is how I handle the routing logic in my `index.html`: + +```javascript +function render() { + let route = window.location.pathname; + // logic to fetch and render markdown +} +``` \ No newline at end of file diff --git a/posts/post-2.md b/posts/post-2.md new file mode 100644 index 0000000000000000000000000000000000000000..8f3653e6613b871de3136bce3616d696344f2e20 --- /dev/null +++ b/posts/post-2.md @@ -0,0 +1,21 @@ +--- +title: The Joy of Small Web +date: 2026-01-12 +tags: philosophy, web +author: linuxgoose +--- + +# The Joy of Small Web + +The modern internet is bloated. Websites are often several megabytes just to display a few paragraphs of text. The **Small Web** movement is about reclaiming the simplicity of the early internet. + +### What makes a "Small" website? +1. **No Tracking:** Respecting user privacy by default. +2. **Text-Heavy:** Prioritizing information over high-res hero images. +3. **No Frameworks:** Reducing the "tax" paid by the user's CPU. + +When you browse this site, you aren't loading a React bundle. You are loading a single HTML file and a few Markdown strings. It feels **instant** because it is. + +--- + +*If you enjoyed this, check out my other posts in the [archive](/posts).* \ No newline at end of file