Enrico Rubboli

Software Engineer and Enterpreneur
Playing with bitcoin - machine learning - go language - ruby - python
Preparing tortellini on demand

yep, a blog..


People who know me is aware of my aversion against social networks and blogs. So why a blog?

I’m thinking of this space as a personal set of notes and thoughts about technical things that I can share with friends and colleagues.

This first post just a quick summary of the tools I’ve used to create this blog, and it’s more like a test to check if everithing is running as expected.

The engine is hugo - an awesome project written in go - to build a static html website. I was already familiar with jekyll, one of the first static website generators written in Ruby, so understanding hugo has been very easy. Why building a static HTML website is a topic I’ll reserve for a future post.

Look and feel is based on Uno but I’ve changed some things. I’ve replaced lightGallery with SimplBox because I prefer something lighter, I’m not sure it was a good idea since it’s not working very well on mobile devices, so maybe I’ll figure out something else at some point. I’ve created a shortcode for hugo that handle it:

 2  <a href="{{ .Get "src" }}" data-simplbox="post">
 3    <img src="{{ .Get "thumb" }}" alt="{{ .Get "alt" }}"/>
 4  </a>
 5  {{ with .Get "alt" }}
 6  <figcaption>
 7    <h4>{{ . }}</h4>
 8  </figcaption>
 9  {{ end }}

you can see it in action clicking on the following picture:

working on the website

working on the website

Syntax highlight (you saw it in the previous snippet of code) is made with pygments that hugo handle pretty well with a specific shortcode. Since I like to show line numbers with the code but I didn’t want them to be selected when you want to copy&paste the code somewhere else I’ve added this scss:

1.highlight .lineno { @include user-select(none); }

the user-select mixin comes from bourbon and basically set the browser specific CSS lines.

That’s it for this first post.

Oh, I was about to forget! Background music comes from mps-yt and everything runs on an Arch Linux