The repo in question is GitHub - FreeSlave/halflife-featureful: Half-Life SDK for making mods upon it
The hugo files are at the “documentation” subfolder.
I followed the “Host on GitHub Pages” guide
I had to add working-directory
in some places of github workflow .yaml because I want to generate the documentation from the subfolder.
The website is deployed fine, but images don’t work. E.g. the image on this page doesn’t show Player inventory | Featureful SDK
If I prepend the repo name to the image url in browser, it shows the image.
I did a lot of searching and this problem is quite well-known indeed. I did change baseURL in hugo.toml (though it probably shouldn’t matter as it’s specified in the build stage in github workflow. Considering it’s doing the correct job of course)
I also tried render hooks as suggested in the issue 51033 on this discourse (can’t post more than 2 links, so I had to go by topic number)
[markup.goldmark.renderHooks]
[markup.goldmark.renderHooks.image]
enableDefault = true
[markup.goldmark.renderHooks.link]
enableDefault = true
[module]
[[module.mounts]]
source = 'assets'
target = 'assets'
[[module.mounts]]
source = 'static'
target = 'assets'
but with no success. So now I’m kinda lost.
I guess I could prepend every image with /halflife-featureful
but is it the right apporach?
Considering there’re so many topics with this problem maybe it should be explicitly addressed in the tutorial with the correct solution (searching for this problem gives mixed answers which confuses even more)