-
Notifications
You must be signed in to change notification settings - Fork 13
46 lines (45 loc) · 1.32 KB
/
deploy-master.yml
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
name: Bump and Publish Master Branch
on:
pull_request:
types:
- closed
workflow_dispatch:
jobs:
bump:
if: github.event.pull_request.merged
runs-on: ubuntu-latest
steps:
- name: Checkout Latest Commit
uses: actions/[email protected]
- name: Grant execute permission for gradlew
run: chmod +x gradlew
- name: Bump Version
id: bump
uses: Plugily-Projects/version-bump-action@v8
with:
github-token: ${{ secrets.github_token }}
auto-version-bump: false
auto-version-bump-release: true
- name: Print Version
run: "echo 'New Version: ${{steps.bump.outputs.version}}'"
publish:
needs: bump
runs-on: ubuntu-latest
steps:
- name: Checkout Latest Commit
uses: actions/[email protected]
with:
ref: 'master'
- name: Set up JDK
uses: actions/[email protected]
with:
distribution: 'temurin'
java-version: '17'
java-package: jdk
- name: Grant execute permission for gradlew
run: chmod +x gradlew
- name: Publish with Gradle
run: ./gradlew publishMavenPublicationToReleasesRepository
env:
MAVEN_USERNAME: ${{ secrets.RELEASESUSERNAME }}
MAVEN_PASSWORD: ${{ secrets.RELEASESPASSWORD }}