-
Notifications
You must be signed in to change notification settings - Fork 39
42 lines (41 loc) · 1.21 KB
/
build.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
name: Reusable action of building snapshot and publish
on:
workflow_call:
inputs:
action:
required: true
type: string
travis_tag:
required: false
type: string
secrets:
MAVEN_SIGNING_KEY_BASE64:
required: false
MAVEN_SIGNING_PASSPHRASE:
required: false
MAVEN_CENTRAL_USERNAME:
required: false
MAVEN_CENTRAL_PASSWORD:
required: false
jobs:
run_build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: set up JDK 17
uses: actions/setup-java@v2
with:
java-version: '17'
distribution: 'temurin'
cache: gradle
- name: Grant execute permission for gradlew
run: chmod +x gradlew
- name: Clean all modules
run: ./gradlew cleanAllModules
- name: ${{ inputs.action }}
env:
MAVEN_SIGNING_KEY_BASE64: ${{ secrets.MAVEN_SIGNING_KEY_BASE64 }}
MAVEN_SIGNING_PASSPHRASE: ${{ secrets.MAVEN_SIGNING_PASSPHRASE }}
MAVEN_CENTRAL_USERNAME: ${{ secrets.MAVEN_CENTRAL_USERNAME }}
MAVEN_CENTRAL_PASSWORD: ${{ secrets.MAVEN_CENTRAL_PASSWORD }}
run: TRAVIS_TAG=${{ inputs.travis_tag }} ./gradlew ${{ inputs.action }}