Force hyphens in URL

Hi,

How can I force the URL of a page to contain multiple hyphens?

The reason I am asking is because I am replacing an old version of my blog (Hugo 0.38), with a new one (Hugo 0.66) and I have a lot of pages which are correctly referenced in Google.

The old version of Hugo replaced the “space” characters in the Slug with “-”, while the new version does not seem to allow multiple “-” characters in the URL.

Example of old URL: “https://www.mysite.com/blog/2019/07/my---title---with---hyphens
Now it gives: “https://www.mysite.com/blog/2019/07/my-title-with-hyphens

I tried everything I could think of (url: , [permalinks] blog = “/:year/:month/:slug|urlize” …) but nothing seems to work.

Any help would be more than welcome.

Thanks

1 Like

I confirm this issue. Can you open an issue on the Hugo repo with a minimum reproducible example? Thanks.

I have opened this issue here: