-
-
Notifications
You must be signed in to change notification settings - Fork 7.6k
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
Improve title logic for new post/my-post/index.md etc. #4348
Comments
new
command
I would instead suggest just adding some title logic: "if index then use folder name". |
It can work but I still don’t like the logic here: User systematically having to add /index.md after its page path/name Hugo new’s point is to create proper Hugo content files without the user having to bother too much. |
Your solution does not really work when you add languages and markdown types to the mix. Adding CLI flags for everything already encoded into the filename is not something I want to maintain. |
Yes I didn’t take enough parameters into account. Of course it makes sense. |
This issue has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs. |
Page Resources may prompt user to systematically create Page Bundles for all of their pages, or not.
For now, you have to hit
$ new post/my-post/index.md
which will create a mardown with the following Front MatterNot only user has to include index.md himself in the path, but will have to rename the default
title
wrongly assumed as "Index"A simple flag called
--bundle
or other could save many seconds to content creation and result in a simpler:$ new post/my-post --bundle
The text was updated successfully, but these errors were encountered: