jenkinsci / jenkinsci/git-plugin
[JENKINS-22581] Git Publisher - please allow ordering of actions
- Dominant language
- Java
- Stars
- 694
- Forks
- 1.1k
- Avg merge
- 1h 29m
- Merged PRs (30d)
- 3
Description
Using the Git Publisher, in post-build Actions, Tags, Branches, Notes are only allowed in that order. It would be helpful if one could choose which action would occur in what order. I care because on occasion a user will commit to a branch that I wish to push at the end of a build, during the build execution. When this occurs, the publisher will rightly refuse to push changes in the clone because the clone is now out-of-date. This is all good. However, I also push a tag on successful builds. Because the tag gets pushed first, a tag is pushed, and then the branch push fails due to the aforementioned reason.
If I were able to attempt the branch push first, then it would fail in my example, and the tag push would never happen.
---
Originally reported by scottmarmit, imported from: Git Publisher - please allow ordering of actions
Raw content of original issue
Using the Git Publisher, in post-build Actions, Tags, Branches, Notes are only allowed in that order. It would be helpful if one could choose which action would occur in what order. I care because on occasion a user will commit to a branch that I wish to push at the end of a build, during the build execution. When this occurs, the publisher will rightly refuse to push changes in the clone because the clone is now out-of-date. This is all good. However, I also push a tag on successful builds. Because the tag gets pushed first, a tag is pushed, and then the branch push fails due to the aforementioned reason.
If I were able to attempt the branch push first, then it would fail in my example, and the tag push would never happen.
environment
```
Git Plugin 2.0.1
Jenkins 1.532.2
```
Contributor guide
Assessment
This issue has not been assessed yet.