Skip to content

Commit 91331e0

Browse files
Update version-bump.yml
1 parent d7bfe29 commit 91331e0

File tree

1 file changed

+27
-6
lines changed

1 file changed

+27
-6
lines changed

.github/workflows/version-bump.yml

+27-6
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
1-
name: Package version bump
1+
name: Gradle release
22
on:
33
push:
44
branches: [master]
55
workflow_dispatch: {}
66

77
jobs:
8-
build:
8+
bump-version:
99
runs-on: ubuntu-latest
1010
permissions:
1111
contents: write
@@ -15,8 +15,29 @@ jobs:
1515
id: bump
1616
uses: Plugily-Projects/version-bump-action@v9
1717
with:
18-
github-token: ${{ secrets.github_token }}
18+
github-token: ${{ secrets.GITHUB_TOKEN }}
1919
auto-version-bump: true
20-
auto-version-bump-release: true
21-
- name: Print Version
22-
run: "echo 'New Version: ${{steps.bump.outputs.version}}'"
20+
release:
21+
needs: bump-version
22+
runs-on: ubuntu-latest
23+
permissions:
24+
packages: write
25+
contents: read
26+
steps:
27+
- uses: actions/checkout@v4
28+
- name: Set up JDK 17
29+
uses: actions/setup-java@v4
30+
with:
31+
java-version: '17'
32+
distribution: 'temurin'
33+
server-id: github # Value of the distributionManagement/repository/id field of the pom.xml
34+
settings-path: ${{ github.workspace }} # location for the settings.xml file
35+
- name: Setup Gradle
36+
uses: gradle/actions/setup-gradle@dbbdc275be76ac10734476cc723d82dfe7ec6eda # v3.4.2
37+
- name: Build with Gradle
38+
run: ./gradlew build
39+
- name: Publish to GitHub Packages
40+
run: ./gradlew publish
41+
env:
42+
USERNAME: ${{ github.actor }}
43+
TOKEN: ${{ secrets.GITHUB_TOKEN }}

0 commit comments

Comments
 (0)