-
Notifications
You must be signed in to change notification settings - Fork 201
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
Put git branch name in message? #12
Comments
I just wanted to add in that we would also find this advantageous. Current messages look like: [project] - #7 Success after 51 min (Open) ... it would be great if they could be changed to look like: [project]/[branch] - #7 Success after 51 min (Open) I checked out the plugin code and the changes look fairly straightforward, however I couldn't figure out where to get the current branch name from the Hudson/Jenkins API, so that has put me at an impasse. |
+1 |
It would be nice to be able to configure messages all-together, actually. Maybe some kind of message templating. |
👍 |
👍 as well. |
I also think this is a good thing. |
Ok, so I took a stab at this. I found two approaches:
I also looked into trying to use hudson.scm.SCM, but I couldn't figure out how to expose SCM related info... maybe someone more knowledgeable could help solve that. These changes were branched from hipchat-0.1.4 release because it was the only known working version that we'd already been using. |
Yes, message templating similar to email notifications would be really useful. For our parameterized builds, it would be much more useful to be able to include some of the parameters in the notification. |
➕ 1️⃣ |
Vote for having a per-project message template too. My use case is that I have a project with a parameter that determines whether to deploy to staging or production and in HipChat there's no way to tell which kind of build was run. |
If anyone wants to try the plugin with Mustache notification templates I have a snapshot HPI up in Dropbox: https://dl.dropbox.com/u/5336861/hipchat.hpi YMMV, disclaimer, etc, etc :-) Also check the updated README |
FYI - It appears that the git plugin sets an environment variable GIT_BRANCH based on which branch is being built, so with the Mustache template you can output |
+1 |
3 similar comments
👍 |
+1 |
+1 |
Any way to put the git branch name into the message sent to hipchat?
The text was updated successfully, but these errors were encountered: