Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: #636 fix Jenkins won't trigger a build of merge commit on merged… #1099

Merged
32 commits merged into from
Mar 30, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
32 commits
Select commit Hold shift + click to select a range
0b9de7c
fix: #636 fix Jenkins won't trigger a build of merge commit on merged…
Jan 28, 2021
dae8f24
fix: fix pom.xml problem
Jan 28, 2021
fe1f702
fix: #636 fix Jenkins won't trigger a build of merge commit on merged…
Jan 28, 2021
a82192d
fix: fix pom.xml problem
Jan 29, 2021
4eb27b4
Fix dependencies and mock to make unit test Success
bulanovk Feb 5, 2021
03e3bae
Make github plugin documentation avaliable on plugins.jenkins,io
bulanovk Feb 12, 2021
4c64148
Switch to bom-2.222.x version 23 and remove direct plugins downgrade
bulanovk Feb 12, 2021
958eadb
Merge pull request #1103 from bulanovk/bugfix/mock
omehegan Feb 15, 2021
e71a920
Fix javadoc failures
omehegan Feb 16, 2021
7236e57
Remove git submodule config pipeline settings
MarkEWaite Feb 16, 2021
4b8917c
[JENKINS-64341] Remove the table, tr and td tags from the forms that …
ironcerocloudbees Feb 19, 2021
f6d714a
[maven-release-plugin] prepare release gitlab-plugin-1.5.18
omehegan Feb 22, 2021
debf820
[maven-release-plugin] prepare for next development iteration
omehegan Feb 22, 2021
110f84e
Fix broken javadoc
omehegan Feb 23, 2021
a14f587
Updated groovy job script in README
Nockiro Feb 23, 2021
12d5c3d
Add possibility to delete the branch after merge success
Feb 24, 2021
15b7970
[maven-release-plugin] prepare release gitlab-plugin-1.5.19
omehegan Mar 2, 2021
0925489
[maven-release-plugin] prepare for next development iteration
omehegan Mar 2, 2021
23117fa
Update about need for maintainers.
omehegan Mar 2, 2021
6f783c3
Fix logic error blocking Multibranch Pipeline projects from being tri…
jre-lsft Mar 8, 2021
76afae8
Merge pull request #1111 from MaximeMazet/master
Mar 9, 2021
dddb6cb
Update CHANGELOG a little bit
reinholdfuereder Mar 12, 2021
3312795
Merge pull request #1109 from ironcerocloudbees/JENKINS-64341
Mar 12, 2021
749e90a
Merge pull request #1120 from reinholdfuereder/patch-1
Mar 12, 2021
9034e01
Merge pull request #1118 from jre-lsft/fix-logic-error
Mar 12, 2021
601358f
Merge pull request #1110 from Nockiro/patch-1
Mar 12, 2021
fe7bc5e
Introduce 2 unit test to cover scenario of starting multibranch build…
bulanovk Mar 12, 2021
1e3f00b
Merge pull request #1121 from bulanovk/feature/multibranchTest
Mar 15, 2021
8387844
Merge pull request #1107 from MarkEWaite/patch-1
Mar 15, 2021
699474c
fix: #636 fix Jenkins won't trigger a build of merge commit on merged…
Jan 28, 2021
efcd270
fix: #636 fix Jenkins won't trigger a build of merge commit on merged…
Jan 28, 2021
5f864b1
Merge branch 'fix/not_trigger_build_on_merged' of https://github.com/…
Mar 23, 2021
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 5 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,10 @@
ChangeLog

1.5.14 - to be released
1.5.15 - 1.5.19
=====================
**TODO**

1.5.14
=====================
* #866: Better compatibility with Configuration as Code plugin (useAuthenticatedEndpoint)

Expand Down
19 changes: 9 additions & 10 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ This plugin allows GitLab to trigger builds in Jenkins when code is committed or

### Seeking maintainers

I am no longer using GitLab on a daily basis, and therefore I have less time to spend working on the plugin. If you are a regular user and would like to help out, please consider volunteering as a maintainer. There are verified bugs that need fixes, open PRs that need review, and feature requests that range from simple to complex. If you are interested in contributing, contact Marky (email address in git log) for additional access.
**This plugin is not maintained!** I no longer have the time or available infrastructure to test PRs. If you are willing to invest some time in this, please comment on https://github.com/jenkinsci/gitlab-plugin/issues/1115 to request access.

# User support
### Relationship with GitLab Inc.
Expand Down Expand Up @@ -171,23 +171,24 @@ In your job configuration, click 'This build is parameterized' and add any param
In the Groovy Script field insert something similar to:

```
import hudson.model.*
def env = Thread.currentThread()?.executable.parent.builds[0].properties.get('envVars')
def env = currentBuild.getEnvironment(currentListener)
def map = [:]

if (env['gitlabSourceBranch'] != null) {
map['sourceBranch'] = env['gitlabSourceBranch']
if (env.gitlabSourceBranch != null) {
map['sourceBranch'] = env.gitlabSourceBranch
}
if (env['gitlabTargetBranch'] != null) {
map['targetBranch'] = env['gitlabTargetBranch']

if (env.gitlabTargetBranch != null) {
map['targetBranch'] = env.gitlabTargetBranch
}
// Add additional entries for any other parameters you have created

return map
```

You can then reference these variables in your job config, e.g. as `${sourceBranch}`. You will need to update this code anytime you add or remove parameters.

Note: If you use the Groovy Sandbox, you might need to approve the script yourself or let an administrator approve the script in the Jenkins configuration.

## Git configuration
### Freestyle jobs
In the *Source Code Management* section:
Expand All @@ -213,9 +214,7 @@ In the *Source Code Management* section:
checkout changelog: true, poll: true, scm: [
$class: 'GitSCM',
branches: [[name: "origin/${env.gitlabSourceBranch}"]],
doGenerateSubmoduleConfigurations: false,
extensions: [[$class: 'PreBuildMerge', options: [fastForwardMode: 'FF', mergeRemote: 'origin', mergeStrategy: 'DEFAULT', mergeTarget: "${env.gitlabTargetBranch}"]]],
submoduleCfg: [],
userRemoteConfigs: [[name: 'origin', url: 'git@gitlab.example.com:foo/testrepo.git']]
]
```
Expand Down
Loading