jenkinsci / jenkinsci/git-plugin
[JENKINS-13833] Git Publisher should allow ForceTag instead of CreateTag
- Dominant language
- Java
- Stars
- 694
- Forks
- 1.1k
- Avg merge
- 1h 29m
- Merged PRs (30d)
- 3
Description
There is a common development pattern that is not currently possible with the git plugin (as far as I can tell). I want to be able to tag a recently passed commit (with an already existing tag) and push that back to the origin repository.
So the idea being that currently my git history looks like this:
40f7af3 2012-05-17 | new commit
2738f9f 2012-05-17 | previous commit (passed)
fbafd82 2012-05-17 | older commit
When 40f7af3 gets pushed and tested, if it passes it should now get the `passed` tag.
40f7af3 2012-05-17 | new commit (passed)
2738f9f 2012-05-17 | previous commit
fbafd82 2012-05-17 | older commit
If we replace CreateTag with a ForceTag checkbox, this behavior will now be possible, as will all of the previous options with createtag.
In code, all the checkbox would have to do is enable the `-f` flag while performing the git tag command. (This is already built into the API).
---
Originally reported by
akoumjian, imported from: Git Publisher should allow ForceTag instead of CreateTag
Raw content of original issue
There is a common development pattern that is not currently possible with the git plugin (as far as I can tell). I want to be able to tag a recently passed commit (with an already existing tag) and push that back to the origin repository.
So the idea being that currently my git history looks like this:
40f7af3 2012-05-17 | new commit
2738f9f 2012-05-17 | previous commit (passed)
fbafd82 2012-05-17 | older commitWhen 40f7af3 gets pushed and tested, if it passes it should now get the `passed` tag.
40f7af3 2012-05-17 | new commit (passed)
2738f9f 2012-05-17 | previous commit
fbafd82 2012-05-17 | older commitIf we replace CreateTag with a ForceTag checkbox, this behavior will now be possible, as will all of the previous options with createtag.
In code, all the checkbox would have to do is enable the `-f` flag while performing the git tag command. (This is already built into the API).
Contributor guide
Assessment
This issue has not been assessed yet.