-
Notifications
You must be signed in to change notification settings - Fork 96
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
feat(config): add the ability to customize commit messages #612
feat(config): add the ability to customize commit messages #612
Conversation
Hopefully this works, the test scripts are completely broken on Windows 😛. |
dc30be8
to
64e771a
Compare
Add configuration options allowing Greenkeeper's commit message format to be customized as the user desires. These are handled exactly like other configuration options, as a `commitMessages` key in `package.json`. Some messages support data coming in, the format for this follows JavaScript's template literals. This will allow Greenkeeper to fit in with any custom commit message format that a project requires, instead of forcing the conventional-commit style. Fixes greenkeeperio#153.
64e771a
to
6a4fae5
Compare
It looks like third party PR's don't get a valid |
@Arcanemagus I updated the Travis config and it now runs the pr correctly. I had to 'unsecure' the PRIVATE_KEY, which is ok since it is just a randomly generated one anyway! I only had a brief look on the PR and noticed that lodash has a function Tests are failing unfortunately, I can try to dig into it on the weekend. |
9e53d37
to
bbd6993
Compare
Instead of bringing in an additional library, use the Lodash `template` function since the library is already used elsewhere in the project.
Remove the async designation from `get-message`, this function is purely sync.
bbd6993
to
dfd17a1
Compare
@Realtin Changed this over to |
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.
Really great work ✨
Thank you so much for spending time on this.
When you made the changes, I merge it, which means it will be deployed to our staging system and tested it on there. If everything runs smoothly, I can deploy it to production as soon as next week!
package.json
Outdated
@@ -9,6 +9,7 @@ | |||
"catbox-memory": "^2.0.4", | |||
"couchdb-bootstrap": "^1.14.0", | |||
"envalid": "^4.0.1", | |||
"es6-template-strings": "^2.0.1", |
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.
You missed removing the package from the package.json :)
I looked at an outdated diff 😅 |
Does the bot |
Hey, the feature is not yet deployed to production. I'll ping you on the issue when it is. |
@jy95 @Arcanemagus It's released on production now! 🚀 ✨ 📝 |
Thanks @Realtin Work as expected on my test repo : https://github.com/jy95/mediaScan |
Add configuration options allowing Greenkeeper's commit message format to be customized as the user desires. These are handled exactly like other configuration options, as a
commitMessages
key inpackage.json
. Some messages support data coming in, the format for this follows JavaScript's template literals.This will allow Greenkeeper to fit in with any custom commit message format that a project requires, instead of forcing the conventional-commit style.
Within
package.json
the following keys are used as the default values:Note:
closes
is somewhat special in that it is conditionally appended to (dev)dependencyUpdate
and doesn't get used on its own.The values within
${}
for each message are passed in from the appropriate places within the code, they can be omitted, but the variable names can't be changed from the configuration.dependencyUpdate
anddevDependencyUpdate
support these parameters:dependency
version
dependencyPin
anddevDependencyPin
support these parameters:dependency
oldVersion
closes
supports anumber
parameter denoting the PR it closes.As an example usage to have Greenkeeper follow ESLint convention (#608), the following configuration could be used:
Note: Since
closes
is the same as the default, there is no need to specify it here.Note: #608 was talking about an "(extended) ESLint" configuration, the above follows this guide.
Fixes #153.