A static blog-compiler
GPL-2.0 License
Bot releases are visible (Hide)
This release includes the ability to use an external theme, and updates the included templates to make that support easier to deal with. This was reported in #26, and implemented in #27.
If you've previously edited the in-built templates, which would get overwritten upon upgrade, you can now avoid that problem:
ephemeris.json
file, so that these themes will be used when you rebuild your blog.The templates have been edited slightly in this release, as part of the migration. There are two changes:
.Prefix
and Prefix
variables have changed.
{{PREFIX}}
should be used to retrieve this value.data/
prefix to all include-files.
My own blog is stored within a git-repository and looked like this:
blog.steve.fi/
├── comments/
├── data/
└── ephemeris.json
I export the in-built templates to a local theme
directory:
$ ephemeris -export-theme=theme/
Creating directory theme
..
Copying data/tag_page.tmpl to theme/tag_page.tmpl
Copying data/tags.tmpl to theme/tags.tmpl
This results in a directory tree looking like so:
blog.steve.fi/
├── comments/
├── data/
├── theme/
└── ephemeris.json
Now I update my configuration file to add a configuration-key ThemePath
:
$ cat ephemeris.json
{
"PostsPath" : "data/",
"CommentAPI" : "https://api.steve.fi/Blog/",
"CommentsPath": "comments/",
"OutputPath" : "output/",
"Prefix" : "https://blog.steve.fi/",
"ThemePath" : "theme/"
}
Now this is done I can edit the contents of theme/*
as I see fit, and remain confident that future upgrades will not overwrite my changes.
Published by skx about 3 years ago
This release contains fixes an issue with sorting upon the front-page, and sidebar, for blogs that have fewer than ten entries, as noted in #22, and resolved in #23.
Once the sorting issue was fixed some minor changes were made to the implementation to remove some repetition in our code, and improve testing (reported in #24, and fixed in #25).
Published by skx over 3 years ago
This release updates our code to require the use of go v1.16, or higher, to build. Using the most recent golang compiler means we can take advantage of the new "go embed" support, and remove the need to use an external tool to embed our theme/templates files within our binary.
There were some minor linting updates required, and we've resynced our dependencies to be the most recently available, but nothing changed in this release which should be externally visible.
Published by skx about 4 years ago
This release contains zero changes compared to the previous v0.3.0, it is solely being made to automate the building of the project via the Github Actions / CI process.
Published by skx about 4 years ago
This release contains a small number of minor updates:
Published by skx over 4 years ago
This release has been made to bundle up the changes since the last one.
On the whole there hasn't been too many changes:
input/*.txt
".Published by skx about 5 years ago
This is the first stable release, although I've been using this tool to generate my blog for approximately the past week.
The project consists of a simple page ephemeris
which contains code for:
To make those classes useful there is cmd/ephemeris
which actually loads the posts/comments and generates the blog. This command is the basically hardwired to behave well for me, containing embedded text/template
templates which are used to generate the output.
Although I don't expect this will ever become a general-purpose blogging utility the option is there, I could move links/references from the templates to the configuration file (JSON). We'll see if there is any interest.