HUGO

Do you need to know Golang to use Hugo?

I’m new to using static generators and I have no experience in Go, nor do I have the time to learn it at the moment. I’m wondering if my lack of experience with Go will cause problems when working with Hugo. Are there things you need to know Go for in order to take full advantage of this generator?

I’m planning on building a small business site.

Hugo uses Golang’s template language, so, it helps to know that. Since it’s new to you in general, there’s going to be a learning curve and you’re going to need to sift through information. That will be the case no matter what platform you use to build your site, even if it’s wordpress. There are tons of examples in this forum, and repos on github, which should help you.

There are two answers, depending on what "take full advantage” means for you:

First: No, I didn’t learn a whiff of Go, and I love using Hugo for a blog. I use one of the pre-existing themes, so I didn’t do any design work. The things I needed to know were:

  1. how to use basic Git functions with GitHub from the command-line;
  2. how to edit a YAML or TOML template (or JSON) to plug in my metadata. I didn’t know this in advance, but is pretty obvious when you look at the examples;
  3. how to write Markdown;
  4. given how I chose to deploy, how to down download and install a script. Using the deploy.sh script seemed to me the fastest way to deploy my site. Putting my site online requires just the commands hugo -d dist and ./deploy.sh, as described here.

That’s all the technical knowledge required to use Hugo. No Go.

Second answer: if you’re designing a business site, you may want to edit or design your own theme, and to take full advantage of Hugo in that sense, you’d need to learn Go. Go is required for theme design.

1 Like

I have started to design my own theme now. So far it kind of makes sense, but I haven’t gotten that far yet. I’ve just created a site that displays my index and single post pages.
http://hugo.bitballoon.com/

Do you think I could create a fully functional theme with just the Go Template Primer? I’m very busy learning about HTML5, CSS3 and JS at the moment. I want to learn Go later on though, but that might be a year or two down the road.