I ran my own blog for many years but recently I suspect my server got hacked, and after reinstalling I want to do things a little differently.

I’d like to move away from PHP and I don’t really need a dynamic CMS anyhow.

So far I’ve been using PicoCMS which serves content from markdown pages with a little header. I got quite good at it, wrote my own theme and a few plugins. The templating language is Twig so something similar would be a boon for me.

Writing content in markdown is my most important requirement, or rather reusing the existing pages with as little massaging as possible. Here is one example:

---
Title: Create WiFi Hotspot with NetworkManager
date: 24.11.2022
Tags: archlinux,android
template: post
---

# Make sure required depenencies are installed

blablablablablablablabla

I really want a tag cloud, which used to be my only sorting mechanism apart from date. Most generators, at first glance, offer a tags page. Honestly I have no idea if I’d have to template the cloud myself but tag functionality seems to be common, I guess?

What I don’t want is any sort of web UI or even builtin server functionality or other bells and whistles for the user. I prefer to ssh into the server and do things on the CLI.

Now my most important constraint is that I want to use what’s available in (or as a) Debian repositories. After a quick search around it boils down to:

Searching for similar topics I found this and this. I read all the comments.

TIA


edit: Lots of people mention Hugo. Why would I choose that over, say, Jekyll or Pelican?
Personally I feel drawn more towards Python than Go or Rust, and a Twig-like (e.g. Jinja) templating language. If that’s idiotic, please let me know why.
Also please remember I’m not running a github (or other similar VCS) page but have a dedicated VPS running Debian Stable. Deployment or containerization are of no interest to me.

  • shiftymccool@programming.dev
    link
    fedilink
    English
    arrow-up
    5
    ·
    13 hours ago

    Not sure if this will work for you but I keep my homelab documentation in markdown, mainly edited with Obsidian. I wanted an easy way to access via web and found Perlite. I have this pointed at a notes folder on my server which is auto-updated with Syncthing. No fuss, just works

    • A_norny_mousse@feddit.orgOP
      link
      fedilink
      English
      arrow-up
      2
      ·
      14 hours ago

      The search is nice, certainly a good thing to have in a blog. It has interesting features, most of which I’ll probably never use. No theming afaics but I’m sure that can be remedied. Your end result certainly looks nice enough.

      Why would I otherwise sway from my hard requirements to use this? It is not in Debian’s repositories. However, a simulated install suggests that it has all dependencies bundled. What’s it really based on? Python I guess?

      • moonpiedumplings@programming.dev
        link
        fedilink
        English
        arrow-up
        1
        ·
        edit-2
        9 hours ago

        Quarto has theming via several built in bootstrap themes.

        Quarto is written in javascript.

        Also, it has no template engine/templating. I have a nasty hack where I write python code blocks (vua quarto’s ability to execute code blocks) to output markdown that can be remdered to both html and pdf, which is pretty unique. But this is probably not what most people making a website want.

  • nycki@lemmy.world
    link
    fedilink
    English
    arrow-up
    6
    ·
    edit-2
    18 hours ago

    11ty is my favorite! cross-platform, good defaults, built-in tag support, and just generally good learning curve.

  • manxu@piefed.social
    link
    fedilink
    English
    arrow-up
    5
    ·
    18 hours ago

    I went the same direction, from WordPress to static site generation. I did the same evaluation as you are trying to do and ended up with Hugo, mostly because there is a lot of support available for it. My runner up was Pelican, because I was fluent in Jinja2, but I didn’t want to mess around with the templates and Hugo’s were prettier. Sue me, I am shallow.

    The one regret I have about Hugo is that the templating language is challenging. I am trying to be as neutral as possible, but it seemed like even simple things were complicated to achieve. If someone would come up with a Hugo that speaks Jinja2, I’d be really delighted.

    Other than that, conversion from WordPress to Hugo was relatively straightforward, despite needing to find a gallery component and converting menus. Hugo is indeed very fast in processing, which become important when your blog has thousands of articles.

    I set up the blog as a private git repository. The server pulls from it, then runs Hugo and a full text search engine, and the content is visible and searchable within five minutes on update.

    • A_norny_mousse@feddit.orgOP
      link
      fedilink
      English
      arrow-up
      2
      ·
      11 hours ago

      My runner up was Pelican, because I was fluent in Jinja2, but I didn’t want to mess around with the templates and Hugo’s were prettier.

      I think you’re the first one mentioning Pelican. Apart from the theming, would you recommend it? I’m familiar with Twig.

      needing to find a gallery component

      Oh yes, that would also be relatively important to me. Again, does Pelican offer that?

      • manxu@piefed.social
        link
        fedilink
        English
        arrow-up
        2
        ·
        8 hours ago

        There must have been a gallery component, since I only looked at generators that had one available.

        Honestly, in hindsight the templates were really not a big deal. Just for fun, I tried converting the Hugo template I used to Pelican, and it was easy for me.

        Pelican is solid and mature and I would use it, in hindsight. The only major flaws are that it’s much slower (but makes up for it with incremental builds) and that the community is much, much smaller. On the plus side, Jinja2 is much, much, much better than Go templating (Hugo borrows from Go).

  • liliumstar@lemmy.dbzer0.com
    link
    fedilink
    English
    arrow-up
    4
    ·
    19 hours ago

    I would also recommend Hugo, and believe it meets your requirements. The header markdown looks very similar to what you wrote, and it has tags. I’m not sure about a tag “cloud” the way you imagine it, but it’s worth looking into.

    • A_norny_mousse@feddit.orgOP
      link
      fedilink
      English
      arrow-up
      1
      ·
      14 hours ago

      Isn’t it overkill? I’m also skeptical because it seems tied to the github universe.

      And here’s what other people commented about Hugo:

      • “It gets admittedly more complex if you’re wanting to write your own theme though.”
      • “But as soon as you do want to customize it, you’re stuck learning one of the most esoteric languages that wasn’t meant as a joke.”
      • “The documentation is unclear and there’s a chicken and egg problem about how to learn Hugo.”
    • A_norny_mousse@feddit.orgOP
      link
      fedilink
      English
      arrow-up
      2
      ·
      edit-2
      14 hours ago

      Why would I choose that over my requirements? C’mon, just throwing names isn’t enough.

      What templating language does it use?

  • thagoat@lemmy.sdf.org
    link
    fedilink
    English
    arrow-up
    8
    arrow-down
    1
    ·
    edit-2
    22 hours ago

    Hugo. Most definitely. I use it for 5 different sites. The syntax is easy. Posts, pages, etc are in easy markdown. Compiles your site (directly to your web root if you like) in under a second. It’s awesome.

  • anotherandrew@mbin.mixdown.ca
    link
    fedilink
    arrow-up
    6
    ·
    23 hours ago

    This is a post near and dear to my heart. I too am looking for something markdown-centered, static, reasonable for code/technical content and that can embed not just photos but browser-side js graphs based on data within the markdown or REST calls. It’s been a few years since I went down this rabbit hole and I got lost very quickly. Thank you for posting, I’ll be revisiting over the next few days to see what the fediverse has to say!

    • monoboy@lemmy.zip
      link
      fedilink
      English
      arrow-up
      1
      ·
      4 hours ago

      I use Zola too. I chose it because it is like a simpler version of Hugo and it has a much easier templating engine (it’s similar to Jinja2).

    • A_norny_mousse@feddit.orgOP
      link
      fedilink
      English
      arrow-up
      1
      ·
      10 hours ago

      Thank you! instead of the deb package or building it myself, I just downloaded the lastest from their github. It is one executable, and seems to be working fine so far. Not saying it’s my choice, but it’s easy enough for a quick test and the templating language looks very familiar.

  • wagesj45@fedia.io
    link
    fedilink
    arrow-up
    2
    arrow-down
    1
    ·
    17 hours ago

    I use Publii, which is a local application that supports markdown pages, has an interface similar to a CMS, and renders the entire site out to static html files that you upload to any web server. It can dump to a local folder, or ftp the files for you. It has a lot of good themes, and a blank theme that you can use to get started if you want to roll your own like I did.

    • A_norny_mousse@feddit.orgOP
      link
      fedilink
      English
      arrow-up
      2
      arrow-down
      1
      ·
      edit-2
      14 hours ago

      Why would I choose that over my requirements? It’s not in Debian repos.

      Also I seem to remember from reading the comments in other posts, that this is a GUI app? Does it even use Markdown files?

      • wagesj45@fedia.io
        link
        fedilink
        arrow-up
        2
        ·
        5 hours ago

        It is a GUI app you use locally. It renders out the finished files. And yes it supports markdown formatting.

        Don’t use it if you don’t want to man. I was just offering an alternative that might happen to fit your lifestyle. If not, don’t.

  • barkingspiders@infosec.pub
    link
    fedilink
    English
    arrow-up
    5
    ·
    24 hours ago

    Also curious, have a similar project in mind. I’ve tinkered with jekyll a little and heard good things about Hugo. Hopefully people can speak to some of these.

  • floquant@lemmy.dbzer0.com
    link
    fedilink
    English
    arrow-up
    1
    ·
    edit-2
    17 hours ago

    Astro may also be worth looking into if you’d like a SSG that is still capable of rendering some dynamic content

    • A_norny_mousse@feddit.orgOP
      link
      fedilink
      English
      arrow-up
      2
      ·
      14 hours ago

      Interesting. Big Names.

      It’s based on some js framework, right? Probably pulls in Gigabytes of dependencies.

      Why would I choose that over my requirements? It’s not in Debian repos.

  • Omega@discuss.online
    link
    fedilink
    English
    arrow-up
    1
    ·
    17 hours ago

    I like Hugo, though it’s been the only one I used. May get too involved, and some themes have features others may not have, for example, comment integration may not exist for some themes.

      • Omega@discuss.online
        link
        fedilink
        English
        arrow-up
        1
        ·
        14 hours ago

        Self host and third party exists. You probably could use Lemmy as a shoddy way to make comments too

        • A_norny_mousse@feddit.orgOP
          link
          fedilink
          English
          arrow-up
          1
          ·
          14 hours ago

          Self host

          On a static site generator? Can you link me to that please?

          What about Hugo’s templating language? It’s been said to be daunting:

          • “It gets admittedly more complex if you’re wanting to write your own theme though.”
          • “But as soon as you do want to customize it, you’re stuck learning one of the most esoteric languages that wasn’t meant as a joke.”
          • “The documentation is unclear and there’s a chicken and egg problem about how to learn Hugo.”
          • moonpiedumplings@programming.dev
            link
            fedilink
            English
            arrow-up
            1
            ·
            edit-2
            44 minutes ago

            Alright, this is gonna be long.

            Firstly, yes, different static site generators have different templating langauges. But just like normal programming languages, it is easy to transition from one templating langauge to another. If you take a look at the syntax:

            Not drastically different, but reading the docs, they are all similar enough, and easy to learn.

            I wouldn’t call go’s templating language “esoteric”, but it should be noted that jinja2 is has other uses, most notably it is the templating engine that Ansible uses.

            As for the docs… This could probably be a blog post by itself.

            Firstly, take a look at this website: https://killedbygoogle.com/ . Google has created and then killed 296 projects, many of which were actively used and working. Why?

            This is because, internally at Google, you get promoted if you either A: write software, or B: add more features to software. So what happens is people write software, get promoted, and then realize they don’t get paid more if they actually maintain that software, so they just kill it. Also, they forget to write documentation (because it doesn’t pay more or get you promoted).

            Hugo, is by a Google Engineer, and it shows (or at least, it used to). Software by Google has two distinct characteristics (actually 3 if we count being written in Go).

            • It has every feature you could ever want, even stuff you haven’t heard of
            • And it’s poorly documented. Or not at all lmao.

            But, “being poorly documented” is not a permanent fixture of this software, but instead something that mostly persists for as long as it’s Google software. Often, these projects get “adopted” by the wider community, who fixes up their documentation. Looking at hugo’s docs, it doesn’t seem be nightmarishly bad, especially for the core, main set of features. Like the setup docs appear to be clear (although a more complex process than alternatives).

            But like, for search options: https://gohugo.io/tools/search/ . That google software pattern continues. There are like 10 options on the page, and no docs from hugo on their usage/installation lol.

            Anyway, I would recommend eithier Pelican or Jekyll, given your requirements. Because everything you write is in markdown, it will be fairly easy to move from one static site generator to another, even if you are dissatisfied.

            Also, kinda sorta relevant:

            (source)

            But the point I’m trying to make is the same. Don’t agonize over selecting the perfect static site generator.

          • Omega@discuss.online
            link
            fedilink
            English
            arrow-up
            1
            ·
            13 hours ago

            I was fighting with my linter tbh still have no clue how to write html in go like its php

            And, for the comments part, I haven’t looked into it, it’s likely just a JavaScript file that connects to your server or an external one and pulls all data and whatever, its the single dynamic part and it’s done with js