How many themes do you have with your Hugo repo?

Assuming your Hugo site is in a single git repo (or equivalent), how many themes are location in your themes/ directory? Particularly on your “production”/master branch.

I’m curious because in the several sites that I build with Hugo, I almost never carry more than a single theme. The rare case I do, its usually in a branch I have for testing. I notice that beginning users often forget to specify a theme in config.toml. Myself included back when I first started. I have the following thoughts/questions:

  • should the user be required to specify a theme when only one exists?
  • should a default/base theme be included?
    • Jekyll provides a minimal setup for when you create a new site - this goes a long way to a pleasant first experience plus helping you understand Jekyll and its theming by looking through live files
  • when specifying one or more themes in config/toml, would a repo URL be useful to help Hugo be more aware of themes, versions, and updates?

I don’t use a theme with my own sites; I just build things into layouts/.

Well that is a theme, just without it’s own name and separate directory. I more or less do the same considering that I create a new theme for each site, that I never distribute on its own.

There is an issue / discussion somewhere about fixing “external imports”; there are now themes, but one could also imagine shortcode bundles etc., and this gets even more hairy with theme inheritance.

I have talked about adding a HUGOPATH and a hugo get command. The defails are somewhere, but it is not a trivial job.

2 Likes