@@ -12,14 +12,16 @@ jobs:
1212 if : ${{ github.event_name != 'pull_request' || github.repository != github.event.pull_request.head.repo.full_name }}
1313 strategy :
1414 matrix :
15- os : [ ubuntu-latest, windows-latest ] # TODO macos-latest
15+ os : [ ubuntu-latest, windows-latest, macos-latest ]
1616 include :
1717 - os : ubuntu-latest
18- publish-api : true
18+ publish-core : true
1919 runs-on : ${{ matrix.os }}
2020 steps :
2121 - name : " Checkout source"
2222 uses : actions/checkout@v3
23+ with :
24+ submodules : true
2325 - name : " Setup Java"
2426 uses : actions/setup-java@v3
2527 with :
@@ -32,27 +34,27 @@ jobs:
3234 - name : " sh: Get version type "
3335 if : ${{ matrix.os != 'windows-latest' }}
3436 run : |
35- version_type =$(./gradlew -q --console=plain --no-daemon printVersionType)
36- echo version_type=$version_type
37- echo version_type=$version_type >> $GITHUB_ENV
37+ VERSION_TYPE =$(./gradlew -q --console=plain --no-daemon printVersionType)
38+ echo VERSION_TYPE=$VERSION_TYPE
39+ echo VERSION_TYPE=$VERSION_TYPE >> $GITHUB_ENV
3840 - name : " ps: Get version type"
3941 if : ${{ matrix.os == 'windows-latest' }}
4042 run : |
41- $version_type = ./gradlew -q --console=plain --no-daemon printVersionType
42- echo version_type=$version_type
43- echo version_type=$version_type >> $env:GITHUB_ENV
43+ $VERSION_TYPE = ./gradlew -q --console=plain --no-daemon printVersionType
44+ echo VERSION_TYPE=$VERSION_TYPE
45+ echo VERSION_TYPE=$VERSION_TYPE >> $env:GITHUB_ENV
4446 - name : " Publish snapshot"
45- if : ${{ env.version_type == 'snapshot' && github.event_name == 'push' && github.ref == 'refs/heads/main' }}
47+ if : ${{ env.VERSION_TYPE == 'snapshot' && github.event_name == 'push' && github.ref == 'refs/heads/main' }}
4648 run : ./gradlew publish
4749 env :
48- CI_PUBLISH_API : ${{ matrix.publish-api }}
50+ CI_PUBLISH_CORE : ${{ matrix.publish-core }}
4951 ORG_GRADLE_PROJECT_sonatypeUsername : ${{ secrets.SONATYPE_USERNAME }}
5052 ORG_GRADLE_PROJECT_sonatypePassword : ${{ secrets.SONATYPE_PASSWORD }}
5153 - name : " Publish release"
52- if : ${{ env.version_type == 'release' && github.event_name == 'push' && github.ref == 'refs/heads/main' }}
53- run : ./gradlew -PforceSign=true publishToSonatype closeAndReleaseSonatypeStagingRepository
54+ if : ${{ env.VERSION_TYPE == 'release' && github.event_name == 'push' && github.ref == 'refs/heads/main' }}
55+ run : ./gradlew --info - PforceSign=true publishToSonatype closeSonatypeStagingRepository
5456 env :
55- CI_PUBLISH_API : ${{ matrix.publish-api }}
57+ CI_PUBLISH_CORE : ${{ matrix.publish-core }}
5658 ORG_GRADLE_PROJECT_sonatypeUsername : ${{ secrets.SONATYPE_USERNAME }}
5759 ORG_GRADLE_PROJECT_sonatypePassword : ${{ secrets.SONATYPE_PASSWORD }}
5860 ORG_GRADLE_PROJECT_signingKey : ${{ secrets.SIGNING_KEY }}
0 commit comments