I came across this comment when searching on ways to add abbreviations in Hugo. But I would prefer the glossary or the terms are never published anywhere. Will setting all the build options to false achieve this?
site configuration
[[cascade]]
[cascade.build]
list = 'never'
publishResources = false
render = 'never'
[cascade._target]
path = '{/glossary,/glossary/**}'
lang = '*'
The last line is required for multilingual sites.
@jmooring Is your code meant for config.toml
? I was referring to the glossary’s _index.md
file.
Yes, it is.
As per my previous comment, I would appreciate to stick the code in the glossary file instead. I rarely use abbreviations in my secondary language except for things like e.g
and etc
(Swahili-English website for students). The glossary is more for the English language.
With multilingual sites that’s not a great idea because you have to duplicate the front matter.
If you really want to use a section’s _index.md file, see documentation.
Disregard my previous comment. I see some words like SMS, UN, NATO, etc will require to be translated but their acronyms shown as they appear above. So, is translation just sticking the lang in the file name e.g. sms.sw.md
?
Second, I see using the render link abbreviation inside a link breaks the link. Is that expected? e.g. [[*](HTML)](/html/)
.
Third, I initially thought the term file names were case sensitive. I assume they are not?
Yes, assuming you’re not separating translations by directory (i.e., setting different contentDir
values in your site configuration).
Yes. Test nested links with the CommonMark reference implementation:
https://spec.commonmark.org/dingus/?text=[[text](destination%20"title")](foo).
If you need to do this, use the shortcode instead. For example:
[{{< abbr HTML >}}](/html/)
That depends on the operating system. Get into the habit of using lower case for all of your file paths.
Thanks. I am now sorted.
This topic was automatically closed 2 days after the last reply. New replies are no longer allowed.