Repository navigation
52 lines (47 loc) · 1.62 KB
/
Copy pathjava-release.yml
File metadata and controls
52 lines (47 loc) · 1.62 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
name: Java release
# Runs the whole Java workflow for a java-vVERSION tag, then publishes dev.gecode:iris,
# dev.gecode:iris-kotlin and dev.gecode:iris-processor to Maven Central through the
# Central Portal, signed. See RELEASING.md.
on:
push:
tags:
- 'java-v*'
permissions:
contents: read
jobs:
version:
name: Check tag
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v7
- name: Check the tag against the versions
run: python3 -I scripts/versions.py release-check "$GITHUB_REF_NAME"
build:
name: Build and test
needs: version
uses: ./.github/workflows/java.yml
# Builds the three jars with their sources and javadoc jars again from the tagged
# commit, signs them, uploads one deployment and waits until the Portal has
# validated it and started its release.
publish:
name: Publish to Maven Central
needs: [version, build]
runs-on: ubuntu-latest
environment: maven-central
timeout-minutes: 60
defaults:
run:
working-directory: java
steps:
- uses: actions/checkout@v7
- uses: actions/setup-java@v5
with:
distribution: temurin
java-version: '27'
- name: Publish and release
run: ./gradlew publishAndReleaseToMavenCentral
env:
ORG_GRADLE_PROJECT_mavenCentralUsername: ${{ secrets.MAVEN_CENTRAL_USERNAME }}
ORG_GRADLE_PROJECT_mavenCentralPassword: ${{ secrets.MAVEN_CENTRAL_PASSWORD }}
ORG_GRADLE_PROJECT_signingInMemoryKey: ${{ secrets.SIGNING_KEY }}
ORG_GRADLE_PROJECT_signingInMemoryKeyPassword: ${{ secrets.SIGNING_KEY_PASSWORD }}