Skip to content

Commit 979b032

Browse files
authored
ci: Configure Release Please GitHub workflow (#646)
1 parent 8e99998 commit 979b032

File tree

6 files changed

+34
-6
lines changed

6 files changed

+34
-6
lines changed
Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
on:
2+
push:
3+
branches:
4+
- main
5+
6+
permissions:
7+
contents: write
8+
issues: write
9+
pull-requests: write
10+
11+
name: release-please
12+
13+
jobs:
14+
release-please:
15+
uses: iExecBlockchainComputing/github-actions-workflows/.github/workflows/[email protected]
16+
secrets: inherit

.release-please-manifest.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
{".":"9.0.0"}

Jenkinsfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
@Library('[email protected]') _
1+
@Library('global-jenkins-library@support/2.7.4') _
22
buildJavaProject(
33
shouldPublishJars: true,
44
shouldPublishDockerImages: true)

build.gradle

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -11,16 +11,13 @@ plugins {
1111
group = 'com.iexec.worker'
1212

1313
ext {
14+
gitTag = 'git tag --points-at HEAD'.execute().text.trim()
1415
springCloudVersion = '2023.0.5'
1516
commonsMathsVersion = '3.6.1'
1617
testContainersVersion = '1.20.4'
1718
}
1819

19-
if (!project.hasProperty('gitBranch')) {
20-
ext.gitBranch = 'git rev-parse --abbrev-ref HEAD'.execute().text.trim()
21-
}
22-
23-
if (gitBranch != 'main' && gitBranch != 'master' && !(gitBranch ==~ '(release|hotfix|support)/.*')) {
20+
if (gitTag.isEmpty()) {
2421
version += '-NEXT-SNAPSHOT'
2522
}
2623

gradle.properties

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,6 @@
1+
# x-release-please-start-version
12
version=9.0.0
3+
# x-release-please-end
24
iexecCommonsPocoVersion=5.0.0
35
iexecCommonVersion=9.0.0
46
iexecCommonsContainersVersion=2.0.0

release-please-config.json

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
{
2+
"$schema": "https://raw.githubusercontent.com/googleapis/release-please/main/schemas/config.json",
3+
"draft-pull-request": true,
4+
"release-type": "simple",
5+
"packages": {
6+
".": {
7+
"extra-files": [
8+
"gradle.properties"
9+
]
10+
}
11+
}
12+
}

0 commit comments

Comments
 (0)