hugoDocs icon indicating copy to clipboard operation
hugoDocs copied to clipboard

Describe relationship between file/logical path and publishing path

Open jmooring opened this issue 11 months ago • 2 comments

Describe the relationship between the content’s file path (or logical path when the content is not backed by a file) and the published path. For example (this needs verification, additional steps, etc.):

  1. Convert to lower case
  2. Replace spaces with hyphens
  3. Remove punctuation excluding hyphens
  4. Note what happens when disablePathToLower and removePathAccents are true
  5. etc.

Include examples per the reference links below.

Pages to update:

References:

jmooring avatar Mar 14 '24 19:03 jmooring

Thank you @jmooring.

As per your comments, then it's all by design.

For content/en/docs/Concepts & Tutorials/_index.md

  • Convert to lower case: concepts & tutorials
  • Replace spaces with hyphens: concepts-&-tutorials
  • Remove punctuation excluding hyphens: concepts--tutorials

And for content/en/docs/Concepts (Tutorials)/_index.md

  • Convert to lower case: concepts (tutorials)
  • Replace spaces with hyphens: concepts-(tutorials)
  • Remove punctuation excluding hyphens: concepts-tutorials

Thank you for being patient and kind.

jmichelgarcia avatar Mar 14 '24 19:03 jmichelgarcia

There's a bit more to it, I think, in that some punctuation is retained (tilde for example). Need to dig into it a bit more.

jmooring avatar Mar 14 '24 19:03 jmooring