Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.Sign up
ref/relref issue with duplicate base filenames #2507
I have tried using
And it generates
This is a problem because such a page won't work if the generated HTML will be "mounted" into another subsection of a larger website, say
In fact, it doesn't even work in "pure Hugo" situations when you have two
This is as designed. If you want your site "mounted into" a larger website, you will have to use something other that
Understand that these links will be used not only from the page URL, but will also potentially be rendered on homepage, list pages etc., so a
If you want to address
But looking at the code I see a bug where the order of the pages matters.
For the problem code line, see https://github.com/spf13/hugo/blob/master/hugolib/site.go#L271
It breaks out of the loop when match on base filename when it should have kept on looking for a more specific match if a "composite path" was provided as argument.
// cc @halostatue