In the Jenkins API is there a way to find the git commit of the last build?

后端 未结 1 1741
[愿得一人]
[愿得一人] 2020-12-21 13:28

I would like to write a script to automate the feature branch creation for hot-fixes. In order to do that I need to figure out how to see what was the last commit in the cur

相关标签:
1条回答
  • 2020-12-21 13:44

    You did not specify which API would you prefer to use. But assuming Jenkins XML API it would be something like:

    http://myjenkins/job/myJobName/lastBuild/api/xml?xpath=//lastBuiltRevision/SHA1
    
    0 讨论(0)
提交回复
热议问题