Boris Mann

Open Source. Community. Decentralized Web. Building dev tools at Fission. Cooks & eats.

Home

Dec 6, 2020

  • December 06, 2020

Micro.blog theming and Hugo

OK, so I am continuing working on this from yesterdayjournal.md

I thought I’d actually install Hugo and get it working locally before I attempt to upload it into Micro.blogMicro.blog
. brew install hugo and you’re done, which is great.

Looking at hugo --help showed me that Hugo has a JekyllJekyll
Set env variable PAGES_REPO_NWO to build on [[Netlify]]
Set the environment variable PAGES_REPO_NWO to a repo such as spadebuilders/EIPs if you want to have Jekyll sites build on Netlify.
Posts by Year
{% raw %}
{% for post in site.posts %}
{% capture current_year %}{{ post.date | date: "%Y" }}{% endcapture %}
{% if current_year != previous_year %}
{% unless forloop.first %}
</ul>
{% endunless %}
<h2>{{ current_year }}</h2>
<ul>
...
import function.

Since I had those social posts that I eventually want to get into Mb, this ended up perfect. I ran hugo import jekyl PATH-TO-JEKYLL . to transform those posts into Hugo compatible files.

I forked the marfa theme and put it into the Hugo folder. Error about a missing custom_footer.html file. Pretty sure this is part of the default Mb themes, so I just created an empty one in partials, and the site built and served locally! Very fast compared to my Jekyll experience: 568 ms for 569 pages and 220 static files!

Micro.blogMicro.blog
has a help page about custom themes. Looks like the Blank theme needs to get merged in for files like custom_footer.html to exist.

Looks like custom footer was the only one missing. I’ll keep track of edits to it on the Marfa ThemeMarfa Theme
I’m using the Marfa theme from [[Micro.blog]] for my site blog.bmannconsulting.com. My fork is public here: https://github.com/bmann/theme-marfa
To Do
Home page has avatar and “follow on Mb” links. Change to ???
No pagination on Photos page. Remove and replace with a new / different photos layout.
Error on bio page (linked to avatar). Need to include new partial.
Custom 404 page, need to add not_found.html
[[WIP]]
Copied yearly grouping across from internet-weblog theme into the marfa theme. ...
notes page.

Looking at Mb plugins. Found BigfootJSBigfootJS
A jQuery plugin for empowering footnotes.

Bigfoot is a jQuery plugin that creates exceptional footnotes. Simply include the code on your pages and footnotes will be detected automatically and improved in the following ways:


Links to footnotes will be replaced with clickable/ tappable buttons, making them substantially easier to hit.


Footnote content will appear in a popover directly beside the footnote button when it is clicked/ tapped, which cuts out the annoying bouncing around the pag...
again via the Mb plugin for Bigfoot. Probably better for me to use on this site rather than the super custom margin / side notes.

Enabled the OpenGraph plugin so I get social previews.

Added a Blog category to the navigation, for all the actual blog posts with titles, rather than just short social ones.