-
-
Notifications
You must be signed in to change notification settings - Fork 8.1k
resources/page: Fix custom output formats path for sections and taxonomies #7771
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
|
I'm a little surprised there were no test break, but I think you need to argue why /en/amp/{section}/ Is more correct than: /en/{section}/amp Note that the current implementation is, if I remember correctly, deliberate. So, for a given page/section/whatever, add |
it seems there is no testing about the AMP page path expectation for section,taxonomy,term. 😂 and AMP Format is the only one that provide the d.Type.PathSo, I would expect it does not break any tests.
Ummm, I'm not so sure which one is correct. but for me, if keeping one folder for AMP version then it would be easier for debugging. /en/{section,taxonomy,term}/amp/
/en/amp/{page}/So I would like to avoid mixing as below: /en/amp/{page,section,taxonomy,term}/Note: This issue related to #5760, then |
|
the second commit, I have added test case section,taxonomy,term for amp page and cleanup for long line. |
|
This PR is ready, @bep if you have any comment let me know. This also fix #7342 as User config [outputFormats]
[outputFormats.AppFormat]
name = "app"
isPlainText = false
mediaType = "text/html"
isHTML = true
permalinkable = true
path = "app"
[outputs]
section = ["HTML", "APP"]
page = ["HTML", "APP"]User config define pathpath = "app" Before this fix/{section}/app/
/{taxonomy}/app/
/en/{section}/app/
/en/{taxonomy}/app/
/th/{section}/app/
/th/{taxonomy}/app/After this fix/app/{section}/
/app/{taxonomy}/
/en/app/{section}/
/en/app/{taxonomy}/
/th/app/{section}/
/th/app/{taxonomy}/without this fix, it lead User to confuse about what is actual Custom output path as comment in #7342
The actual Custom output path shall be see the original comment: #7342 (comment) |
|
I belive this fixed, will never be merged, so anyone want this fix, I have forked this project to https://github.com/neohugo/neohugo. |
|
This pull request has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs. |
Fixes #7159
Fixes #7342
Before this fix
custom output formats path =
amp/{section}/amp/ /{taxonomy}/amp/ /en/{section}/amp/ /en/{taxonomy}/amp/ /th/{section}/amp/ /th/{taxonomy}/amp/custom output formats path =
htmlcontent/{section}/htmlcontent/ /{taxonomy}/htmlcontent/ /en/{section}/htmlcontent/ /en/{taxonomy}/htmlcontent/ /th/{section}/htmlcontent/ /th/{taxonomy}/htmlcontent/After this fix
custom output formats path =
amp/amp/{section}/ /amp/{taxonomy}/ /en/amp/{section}/ /en/amp/{taxonomy}/ /th/amp/{section}/ /th/amp/{taxonomy}/custom output formats path =
htmlcontent/htmlcontent/{section}/ /htmlcontent/{taxonomy}/ /en/htmlcontent/{section}/ /en/htmlcontent/{taxonomy}/ /th/htmlcontent/{section}/ /th/htmlcontent/{taxonomy}/Repoduce : https://github.com/jronallo/outputformats-path-issue