-
Notifications
You must be signed in to change notification settings - Fork 85
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
fix(convert-formulas.sh): add -_ to allowed chars in formula name #207
fix(convert-formulas.sh): add -_ to allowed chars in formula name #207
Conversation
Best reviewed: commit by commit
Optimal code review plan
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good
I'm wondering if the tooling accept to have a |
I would be against allowing underscore in formula names because it invalidates current assumptions around semantic naming. Some core maintainers (i.e. me) expect a standard semantic name of |
There are at least 13 formulas that have I add |
We've currently got two formulas using an underscore in the name: |
This is a link to that conversation. We can manage (and pretty much have to, due to the sheer volume of formulas already doing this). https://freenode.logbot.info/saltstack-formulas/20200325#c3478581-c3478644
|
@dafyddj I just need to get around testing both additions locally and then we get this merged if all is OK. Actually, we really should update the test to have a formula name that contains both Lines 124 to 135 in e668832
How about changing from |
Are you referring here specifically to the |
Good idea. |
I would like to propose some formulas we used at work and one of them would be |
2abcc49
to
be56eaa
Compare
tag_out=$(git tag --list | xargs git tag --delete) | ||
if [ "${DEBUG:-false}" = "true" ]; then | ||
echo "$tag_out" | ||
fi | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks a lot 👍
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
but someone may argue that it's not the purpose of this PR ;-)
be56eaa
to
facced5
Compare
@dafyddj I've taken this PR and rebased on the latest version of this formula. I've then run it with: $ bin/convert-formula.sh test_the_use-this-template-button I've grabbed the diff between the resultant first and second commits into a gist for commenting purposes (not necessarily action items, primarily discussion). Working from top-to-bottom (not prioritised):
All-in-all, a fantastic bit of work, kudos! |
facced5
to
7c33601
Compare
Done I'll address the other points another time/elsewhere. |
The only manipulation done is to convert a hyphen to a double underscore: |
Thanks for all of the reviews, guys. Merged, @dafyddj. |
🎉 This PR is included in version 4.3.2 🎉 The release is available on GitHub release Your semantic-release bot 📦🚀 |
PR progress checklist (to be filled in by reviewers)
What type of PR is this?
Primary type
[build]
Changes related to the build system[chore]
Changes to the build process or auxiliary tools and libraries such as documentation generation[ci]
Changes to the continuous integration configuration[feat]
A new feature[fix]
A bug fix[perf]
A code change that improves performance[refactor]
A code change that neither fixes a bug nor adds a feature[revert]
A change used to revert a previous commit[style]
Changes that do not affect the meaning of the code (white-space, formatting, missing semi-colons, etc.)Secondary type
[docs]
Documentation changes[test]
Adding missing or correcting existing testsDoes this PR introduce a
BREAKING CHANGE
?No.
Related issues and/or pull requests
Describe the changes you're proposing
Allow '-' and '_' in formula names. Formulas already exist with '-' in the name (prior to
-formula
),so it seems reasonable to allow creation of new ones.
Pillar / config required to test the proposed changes
Debug log showing how the proposed changes work
Documentation checklist
README
(e.g.Available states
).pillar.example
.Testing checklist
state_top
).Additional context