Domanda

I have a powershell build script which checks out code and increments a build number in SVN (nightly) in our Version.h file.

What I need is some way to set that build number in JIRA (or have JIRA read it from SVN) so that when a story is marked as resolved, it sets a "Last Version" field to that build number so QA knows which build an issue was resolved in.

What's the best way to do this? I could potentially use some combination of the JIRA CLI and a custom field or something, but I was wondering what suggestions were? Are there any scripts/plugins written for this already? I was thinking of using a custom option field and then somehow populating the dropdown with the new build number or something, but that seems like a dirty solution and I don't really know how to do it anyway.

The build number is different from the version that we have in JIRA since those versions we're using for sprints.

Thanks!

È stato utile?

Soluzione

The best way is probably to use Jira's REST API (assuming you're using Jira v4.x onwards, I think). Jira supports SOAP as well, but I think that is going to be more bother than it is worth.

Then assuming your proxy is set correctly, you can use code similar to this Stackoverflow question: Call REST API from PowerShell Script.

Lastly, since the Jira REST api needs authentication, I'd suggest you do not include the password for obvious reasons, but read it from a secure store, or permissioned system file or some other appropriate alternative.

Autorizzato sotto: CC-BY-SA insieme a attribuzione
Non affiliato a StackOverflow
scroll top