added readme.md
This commit is contained in:
parent
581ecd6eb8
commit
423ce48e80
49
README.md
49
README.md
|
@ -0,0 +1,49 @@
|
|||
## Rugem, a barely working gemini site generator written in Rust.
|
||||
|
||||
|
||||
Rugem assumes your have this directory structure:
|
||||
|
||||
|
||||
```
|
||||
root
|
||||
|
|
||||
|-index.gmi
|
||||
|
|
||||
|-some_file.mp4
|
||||
|-some_gmi_file.gmi
|
||||
|
|
||||
|-entry-11-10-2021.gmi
|
||||
|-second_entry-10-7-2020.gmi
|
||||
|
|
||||
|-subfolder
|
||||
| |
|
||||
| |-index.gmi
|
||||
| |-music-12-2-2021.gmi
|
||||
| .
|
||||
|
|
||||
|-subfolder2
|
||||
| |
|
||||
| |-something-4-7-2014.gmi
|
||||
. .
|
||||
|
||||
```
|
||||
|
||||
A single directory, let's call it Gemdir, can contain:
|
||||
- an index.gmi file
|
||||
- some entries with dates, with format `title-dd-mm-yyyy.gmi`. Underscores in title will be substituted with spaces, more on this later.
|
||||
- any kind other of file, be a .gmi file without a date in its name or not.
|
||||
- subfolders, which are treated as Gemdirs themselves.
|
||||
|
||||
The idea is to have a recursive structure. Every subfolder can contain anything listed above. During blog generation, a folder will be created, and every file will be copied over unchanged, except every index.gmi file:
|
||||
|
||||
- `{{ full-list }}` will be substituted with a list of EVERY single dated post in the current directory and in every subdirectory. Use this if you want to generate a list of every single post sorted in order.
|
||||
- `{{ folders }}` will print, for each subfolder, the title of the subfolder and then a list of posts with date. If the subfolder contains and index.gmi file, a link will be created below the name of the subfolder.
|
||||
|
||||
More examples can be found in the examples folder. More features (namely, only printing a handful of files and expanding macros in other .gmi files) will be added later.
|
||||
|
||||
## Usage
|
||||
|
||||
`rugem origin/ target/ "Feed Title" "gemini://www.baseurl.com" "Author Name"`
|
||||
|
||||
The last three arguments are needed to generate the atom feed.
|
||||
|
Loading…
Reference in New Issue