File tree Expand file tree Collapse file tree 1 file changed +3
-30
lines changed Expand file tree Collapse file tree 1 file changed +3
-30
lines changed Original file line number Diff line number Diff line change @@ -10,40 +10,13 @@ pipeline {
10
10
timestamps()
11
11
}
12
12
stages {
13
- stage('Update commit id in the composite repo ') {
13
+ stage('Trigger build ') {
14
14
steps {
15
15
script {
16
- commitToHiveMQCompositeRepo()
16
+ def branchJobName = BRANCH_NAME.replace('/', '%2F')
17
+ build job: "../../hivemq4-composite/${branchJobName}", wait: false
17
18
}
18
19
}
19
20
}
20
21
}
21
- post {
22
- cleanup {
23
- cleanWs()
24
- }
25
- }
26
- }
27
-
28
- private void commitToHiveMQCompositeRepo() {
29
- def projectName = determineProjectName()
30
- def branchName = env.BRANCH_NAME
31
- def url = determineRepoUrl()
32
- sh("git clone git@github.com:hivemq/hivemq.git --branch=$PLATFORM_MASTER")
33
- dir("hivemq/") {
34
- sh("./tooling/reportScmChange.sh $branchName $url $projectName")
35
- }
36
- }
37
-
38
- private String determineProjectName() {
39
- return scm.getUserRemoteConfigs()[0].getUrl().tokenize('/').last().split("\\.")[0]
40
- }
41
-
42
- private String determineRepoUrl() {
43
- String repo = scm.userRemoteConfigs[0].url
44
- if (repo.startsWith("https://github.com/")) {
45
- return repo.replaceFirst("https://github.com/", "git@github.com:")
46
- } else {
47
- return repo
48
- }
49
22
}
You can’t perform that action at this time.
0 commit comments