Comment by hk1337
5 days ago
I've started recently working on setting up the "special" public profile repository in GitHub to be my blog central and wanted to keep the files to a minimum. So, I really like using themes as modules in Hugo, then your blog repository will be just your content directory, go.mod, go.sum, hugo.toml, and any layouts you want to override or add.
.
├── .devcontainer
│ └── devcontainer.json
├── content
│ └── posts
│ ├── 1718983133-post-1.md
│ ├── 1720321560-post-2.md
│ └── 1740070985-post-3.md
├── go.mod
├── go.sum
├── hugo.toml
└── README.md
3 directories, 8 files
> So, I really like using themes as modules in Hugo, then your blog repository will be just your content directory
`themes` are small in size, why not copy them into your repository to keep the build hermetic?
Just out of curiosity, what would the Hugo toml file look like and do you use multiple themes?
I found this as a source. Just like most Hugo.toml with the added module.imports and you have to use the full import name, not just the theme name.
https://discourse.gohugo.io/t/how-to-add-a-theme-using-modul...
I don’t have any but I’ve been swapping out to see which I like better and trying to make my own too.