Compare commits
3 Commits
2e50f7f15e
...
c0f9594f48
Author | SHA1 | Date |
---|---|---|
Nico | c0f9594f48 | |
Nico | 3932e4c111 | |
Nico | 7f189a6db4 |
|
@ -0,0 +1,7 @@
|
|||
*
|
||||
!linluwi.fnl
|
||||
!LICENCE
|
||||
!README.md
|
||||
!example/*
|
||||
!example
|
||||
!.gitignore
|
|
@ -20,9 +20,11 @@ with both of these installed, put the linluwi.fnl file from this repository in a
|
|||
To configure linluwi, you will need to modify the configuration variables at the top of `linluwi.fnl`. These are commented as to what they do, and should be changed to whatever is appropriate to your site.
|
||||
Once you have configured linluwi, you can start using it!
|
||||
|
||||
Your input content needs to go in a content directory, by default called "content" in the same directory as linlui.fnl (changable with the configuration variables). Input pages are in the [gemtext](https://gemini.circumlunar.space/docs/cheatsheet.gmi) format and have the extension .gmi. These files will be converted to HTML for the web output and formatted properly for a gemini capsule for the gemini output.
|
||||
Your input content needs to go in a content directory, by default called "content" in the same directory as linlui.fnl (changable with the configuration variables). Input pages are in the [gemtext](https://gemini.circumlunar.space/docs/cheatsheet.gmi) format and have the extension .gmi. These files will be converted to HTML for the web output and formatted properly for a gemini capsule for the gemini output.
|
||||
`.gmi` files in a subdirectory called `log` will also be processed as log posts (see below). All other files (images, stylesheets, .html files in the input, etc) are copied into the output unchanged. All files (including pages and log posts) keep their position in the input directory structure.
|
||||
|
||||
linluwi has no theme system and makes no attempt to manage stylesheets. This is left to the user (for example, by putting a .css file in the input directory and adding a stylesheet link to it in your HTML header).
|
||||
|
||||
## log posts
|
||||
|
||||
Log posts (.gmi files in a `log` subdirectory of the content directory) are handled slightly differently than other input files. In addition to being converted and copied to the output like pages, they have some specific metadata (required in the post file) that is used to generate basic blog and gemlog index pages (see https://itwont.work/log for an example).
|
||||
|
@ -43,6 +45,8 @@ where YYYY-MM-DD is the date of posting. For example:
|
|||
|
||||
The rest of the content of a post is processed exactly like any other page.
|
||||
|
||||
See the example site in `example/` to see this structure.
|
||||
|
||||
## Support
|
||||
|
||||
if you use this tool and find any issues, you can contact me via mastodon at @nihilazo@tiny.tilde.website or via email on nico@itwont.work (where I will also accept patches).
|
||||
|
|
|
@ -0,0 +1,14 @@
|
|||
# An awesome example site
|
||||
|
||||
This is an AWESOME example site for linlui, a site generator that maybe almost doesn't suck!
|
||||
|
||||
This site contains all sorts of cool stuff, like:
|
||||
* Fake quotes
|
||||
* a log with only a single post
|
||||
* a photo of a tomato
|
||||
|
||||
> "linluwi is a site generator so cool that I rewrote it in rust for myself"
|
||||
> - Joe Fakename
|
||||
|
||||
=> /log/index.gmi read the blog
|
||||
=> https://en.wikipedia.org/wiki/Special:Random read something random on wikipedia
|
|
@ -0,0 +1,6 @@
|
|||
# today, tomatoes
|
||||
2021-01-05
|
||||
|
||||
This post exists in order to be a demo of how log posts are formatted. There's a photo of a tomato on it. I'm not sure what I was even thinking writing this particular example site. I guess it beats lipsum!
|
||||
|
||||
=> /tomato.jpg a tomato
|
Binary file not shown.
After Width: | Height: | Size: 149 KiB |
|
@ -0,0 +1,14 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<feed xmlns="http://www.w3.org/2005/Atom">
|
||||
<title>Example blog</title>
|
||||
<author><name>Joe</name></author>
|
||||
<id>gemini://example.com</id>
|
||||
<updated>2021-01-05T12:00:00Z</updated>
|
||||
|
||||
<entry>
|
||||
<id>gemini://example.com/log/tomato.gmi</id>
|
||||
<title>today, tomatoes</title>
|
||||
<updated>2021-01-05T12:00:00Z</updated>
|
||||
<link href="/log/tomato.gmi" rel="alternate" />
|
||||
</entry>
|
||||
</feed>
|
|
@ -0,0 +1,2 @@
|
|||
# Actually Simple Syndication - https://tilde.town/~dzwdz/ass/
|
||||
2021-01-05 gemini://example.com/log/tomato.gmi today, tomatoes
|
|
@ -0,0 +1,16 @@
|
|||
# An awesome example site
|
||||
|
||||
This is an AWESOME example site for linlui, a site generator that maybe almost doesn't suck!
|
||||
|
||||
This site contains all sorts of cool stuff, like:
|
||||
* Fake quotes
|
||||
* a log with only a single post
|
||||
* a photo of a tomato
|
||||
|
||||
> "linluwi is a site generator so cool that I rewrote it in rust for myself"
|
||||
> - Joe Fakename
|
||||
|
||||
=> gemini://example.com/log/index.gmi read the blog
|
||||
=> https://en.wikipedia.org/wiki/Special:Random read something random on wikipedia
|
||||
|
||||
=> gemini://example.com Go Home
|
|
@ -0,0 +1,5 @@
|
|||
# Example blog
|
||||
|
||||
=> gemini://example.com/log/tomato.gmi 2021-01-05 today, tomatoes
|
||||
|
||||
=> gemini://example.com Go Home
|
|
@ -0,0 +1,8 @@
|
|||
# today, tomatoes
|
||||
2021-01-05
|
||||
|
||||
This post exists in order to be a demo of how log posts are formatted. There's a photo of a tomato on it. I'm not sure what I was even thinking writing this particular example site. I guess it beats lipsum!
|
||||
|
||||
=> gemini://example.com/tomato.jpg a tomato
|
||||
|
||||
=> gemini://example.com Go Home
|
Binary file not shown.
After Width: | Height: | Size: 149 KiB |
|
@ -0,0 +1,14 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<feed xmlns="http://www.w3.org/2005/Atom">
|
||||
<title>Example blog</title>
|
||||
<author><name>Joe</name></author>
|
||||
<id>https://example.com</id>
|
||||
<updated>2021-01-05T12:00:00Z</updated>
|
||||
|
||||
<entry>
|
||||
<id>https://example.com/log/tomato.html</id>
|
||||
<title>today, tomatoes</title>
|
||||
<updated>2021-01-05T12:00:00Z</updated>
|
||||
<link href="/log/tomato.html" rel="alternate" />
|
||||
</entry>
|
||||
</feed>
|
|
@ -0,0 +1,2 @@
|
|||
# Actually Simple Syndication - https://tilde.town/~dzwdz/ass/
|
||||
2021-01-05 https://example.com/log/tomato.html today, tomatoes
|
|
@ -0,0 +1,19 @@
|
|||
<!DOCTYPE html><head><title>Example blog</title><body><article><h1>An awesome example site</h1>
|
||||
|
||||
<p>This is an AWESOME example site for linlui, a site generator that maybe almost doesn't suck! </p>
|
||||
|
||||
<p>This site contains all sorts of cool stuff, like:</p>
|
||||
<ul><li>Fake quotes</li>
|
||||
<li>a log with only a single post</li>
|
||||
<li>a photo of a tomato</li>
|
||||
</ul>
|
||||
<blockquote>
|
||||
"linluwi is a site generator so cool that I rewrote it in rust for myself"
|
||||
- Joe Fakename
|
||||
</blockquote>
|
||||
<a href="https://example.com/log/index.html">read the blog</a><br>
|
||||
|
||||
<a href="https://en.wikipedia.org/wiki/Special:Random">read something random on wikipedia</a><br>
|
||||
|
||||
</article><footer>
|
||||
<a href="/">Go Home</a></footer></body>
|
|
@ -0,0 +1,6 @@
|
|||
<!DOCTYPE html><head><title>Example blog</title><body><article><h1>Example blog</h1>
|
||||
|
||||
<ul><li><a href="https://example.com/log/tomato.html">2021-01-05 today, tomatoes
|
||||
</a><br>
|
||||
</li></ul></article><footer>
|
||||
<a href="/">Go Home</a></footer></body>
|
|
@ -0,0 +1,9 @@
|
|||
<!DOCTYPE html><head><title>Example blog</title><body><article><h1>today, tomatoes</h1>
|
||||
<p>2021-01-05</p>
|
||||
|
||||
<p>This post exists in order to be a demo of how log posts are formatted. There's a photo of a tomato on it. I'm not sure what I was even thinking writing this particular example site. I guess it beats lipsum!</p>
|
||||
|
||||
<a href="https://example.com/tomato.jpg">a tomato</a><br>
|
||||
|
||||
</article><footer>
|
||||
<a href="/">Go Home</a></footer></body>
|
Binary file not shown.
After Width: | Height: | Size: 149 KiB |
Reference in New Issue