Best workflow for testing multiple themese

Something like this question has been asked before, but nothing too recently, and I don’t think quite in the same way that I’m approaching the issue.

My question is the best way to go about installing and switching between multiple themes when developing a new site.

I have seen other questions relating to using multiple themes within one site, which seems like a hack and is not the issue that concerns me.

My question involves the workflow that a lot of people must face when developing a new site with Hugo. The theme galleries are very helpful in quickly identifying some candidate themes for a site, but I can’t go solely on the live demos when picking a theme. Usually I get a quick sense that a theme might work for my application, but have questions about specific customizations needed (logo image, fonts, etc.) My ideal workflow when developing a new site would be to select a handful of seemingly appropriate themes, install all of them to the working version of the site, and be able to (relatively easily) further customize each theme from there, testing them out in more detail until I find the theme (and best combination of customizations) that best meets my needs.

As much as I love Hugo, and preach its benefits to people, lately I am feeling stymied by this process, often finding myself frustrated at how long it takes, and how cumbersome it seems, to test multiple themes this way. I have read the documentation pretty thoroughly, and I know that Hugo isn’t a magic wand, and that users should be prepared to do quite a bit of customization in order to get what they want (which customization varies from theme to theme). That’s all well and good, but I feel like there is some better process (or could be one) than I am using. I understand that Hugo is not WordPress, where you just click a couple of buttons to switch themes, and it’s not that way for many reasons. And in a lot of cases WordPress can also require some pretty detailed, non-beginner-level customization to achieve the desired outcome. But I don’t think it’s too much to ask that there is some degree of standardization to the theme switch and testing process.

Here’s how I’ve been approaching the testing process. What seems to make sense to me is to have one version of the website (one copy of the content files) with a themes/ folder containing multiple themes. I will have one main mywebsite/ directory, with its themes/ directory containing multiple subfolders, one per theme. Generally each one of these gets its own git submodule, When I want to try a different theme I change the theme set in the main config.toml file. Then each theme gets further customized in its own config files.

I don’t think I have to explain too much for experienced users that this process runs into a lot of headaches. Because of lack of standardization of theme file structures and other things, it’s not so easy to swap out themes in this way as I had hoped. So what I’ve been doing more recently is making a new full copy of the site for each theme, with each copy containing only that theme and named accordingly. So I’ll have mywebsite_blogRA, mywebsite_kross, etc. (just to pick a couple of names at random). Each folder has a separate copy of the content files, which feels like a lot of unnecessary duplication, but then once I decide on a theme I can get rid of the extraneous folders and rename the one chosen to remove the theme name (so maybe it’s not really an issue since the duplication is only temporary).

This seems kind of clunky, but I haven’t found any better way to do it thus far. Am I missing something? Is there a better way, perhaps making use of changes in the last year or two, to manage this process? I’m very committed to Hugo but I’m yet again going through the cycle where I’ve spent several times as long just kicking the tires around to pick a theme as I did to make most of the website content. I made the main pages and first few blog posts in a day, but I’ve spent several days wrestling with themes and trying to get each to work in its own way.

I know that part of the issue is that theme developers don’t standardize very much, so there’s only so much that can be done about this. But Hugo hasn’t necessarily enforced strong standardization (and that might not be realistic). I’m pretty practical and non-dogmatic about this; I just want the shortest path from A to B to test my initial shortlist of themes without wasted time and effort. Any suggestions are appreciated.


1 Like