-
-
Notifications
You must be signed in to change notification settings - Fork 8.2k
Open
Labels
Milestone
Description
I ran into this while documenting the changes to .Page.Aliases. Consider this site config:
[mediaTypes]
[mediaTypes.'text/redirects']
delimiter = ''
[outputFormats]
[outputFormats.print]
isHTML = true
mediaType = 'text/html'
path = 'print'
permalinkable = true
[outputFormats.redirects]
baseName = '_redirects'
isPlainText = true
mediaType = 'text/redirects'
root = true
[outputs]
home = ['html', 'redirects']
page = ['html', 'print']
section = ['html', 'print']
When building the site we create the meta-refresh alias files for both the html and print output formats, as expected.
But in the example below, the _redirects file only includes redirects for the html output format:
git clone --single-branch -b hugo-github-issue-14388 https://github.com/jmooring/hugo-testing hugo-github-issue-14388
cd hugo-github-issue-14388
rm -rf public && hugo && tree public && cat public/_redirects
Maybe there's already a way to do this, but it eludes me at the moment.
Reactions are currently unavailable