-
Notifications
You must be signed in to change notification settings - Fork 256
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
Better support for kebab-case targets #311
Comments
I like option 2 - give an option for kebab-cased targets. I think I would make this something you'd set in the magefile itself, like const UseKebabTargets = true that way it's standardized for everyone that uses that particular magefile, rather then being an environment variable, which would change behavior for each person (potentially screwing up other scripts and making each person have incompatible commands). |
I was favoring option 2 as well. |
Woul n't it be easier to allow the currently implemented namespaced targets to be called using a |
I going to give it a try. |
Quick question: can't we support alias by default? like if we pass |
I like @jcchavezs's idea of falling back to to non-kebab if it was passed in as it seems like it'd generally help without hurting. Another idea is to recognize |
I came up with a PR for this #441 |
I haven't seen this discussed before, so I wanted to open a discussion.
In my experience, most Makefiles that are not just cramming words together (e.g.
installhtml
,installps
) use kebab-cased targets (e.g.install-html
,install-ps
) instead of camelCased targets (e.g.installHtml
,installPs
). It would be helpful in migrating existing Makefiles and teams to mage if mage could more easily accommodate this pattern.I'm aware that aliases can help here, but mage Help output only shows the primary targets after running them through the
lowerFirst
template func.Two ideas:
The text was updated successfully, but these errors were encountered: