https://github.com/jenkinsci/git-push-plugin
Jenkins plugin allowing to perform a git push as a post build step
https://github.com/jenkinsci/git-push-plugin
git git-push scm
Last synced: 3 months ago
JSON representation
Jenkins plugin allowing to perform a git push as a post build step
- Host: GitHub
- URL: https://github.com/jenkinsci/git-push-plugin
- Owner: jenkinsci
- License: mit
- Created: 2021-08-04T17:51:54.000Z (over 4 years ago)
- Default Branch: master
- Last Pushed: 2025-01-21T20:47:41.000Z (about 1 year ago)
- Last Synced: 2025-01-30T04:24:43.150Z (12 months ago)
- Topics: git, git-push, scm
- Language: Java
- Homepage: https://plugins.jenkins.io/git-push/
- Size: 248 KB
- Stars: 2
- Watchers: 3
- Forks: 7
- Open Issues: 2
-
Metadata Files:
- Readme: README.md
- License: LICENSE.md
- Codeowners: .github/CODEOWNERS
Awesome Lists containing this project
README
# git-push
[](https://ci.jenkins.io/job/Plugins/job/git-push-plugin/job/master/)
[](https://github.com/jenkinsci/git-push-plugin/graphs/contributors)
[](https://plugins.jenkins.io/git-push)
[](https://github.com/jenkinsci/git-push-plugin/releases/latest)
[](https://plugins.jenkins.io/git-push)
## Introduction
This plugin allows to perform a git push as a post build step via [Git Plugin](https://plugins.jenkins.io/git)
In details, the plugin will pull then push (tags included) to the selected remote branch.
## Getting started
### Pipeline
```groovy
gitPush(gitScm: scm, targetBranch: env.BRANCH_NAME, targetRepo: 'origin')
```
### Jenkins Job
The instructions below are based on a Jenkins job created as a Freestyle project.
Open the Jenkins job configuration.
Make sure the job uses git `Source Code Management`.
For example, a basic git configuration could look like this:

Add `Git Push` as a post build action:

Configure the action:

## Issues
Report issues and enhancements in the [Issue tracker](https://github.com/jenkinsci/git-push-plugin/issues).
## Contributing
Refer to our [contribution guidelines](https://github.com/jenkinsci/.github/blob/master/CONTRIBUTING.md)
## LICENSE
Licensed under MIT, see [LICENSE](LICENSE.md)