Write GitHub Actions scripts
This commit is contained in:
parent
66564457ff
commit
22e6657e79
30
.github/workflows/build.yml
vendored
Normal file
30
.github/workflows/build.yml
vendored
Normal file
@ -0,0 +1,30 @@
|
|||||||
|
name: Gradle build
|
||||||
|
|
||||||
|
on:
|
||||||
|
push:
|
||||||
|
branches: [ dev, master ]
|
||||||
|
pull_request:
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
build:
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
timeout-minutes: 40
|
||||||
|
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@v2
|
||||||
|
- uses: DeLaGuardo/setup-graalvm@5.0
|
||||||
|
with:
|
||||||
|
graalvm: 22.0.0.2
|
||||||
|
java: java11
|
||||||
|
arch: amd64
|
||||||
|
- uses: actions/cache@v2
|
||||||
|
with:
|
||||||
|
path: |
|
||||||
|
~/.gradle/caches
|
||||||
|
~/.gradle/wrapper
|
||||||
|
key: ${{ runner.os }}-gradle-${{ hashFiles('*.gradle.kts') }}
|
||||||
|
restore-keys: |
|
||||||
|
${{ runner.os }}-gradle-
|
||||||
|
- uses: gradle/wrapper-validation-action@v1.0.4
|
||||||
|
- name: Build
|
||||||
|
run: ./gradlew build --build-cache --no-daemon --stacktrace
|
28
.github/workflows/publish.yml
vendored
28
.github/workflows/publish.yml
vendored
@ -8,14 +8,26 @@ on:
|
|||||||
jobs:
|
jobs:
|
||||||
build:
|
build:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
|
timeout-minutes: 40
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v2
|
- uses: actions/checkout@v2
|
||||||
|
- uses: DeLaGuardo/setup-graalvm@5.0
|
||||||
- name: Run a one-line script
|
with:
|
||||||
run: echo Hello, world!
|
graalvm: 22.0.0.2
|
||||||
|
java: java11
|
||||||
- name: Run a multi-line script
|
arch: amd64
|
||||||
run: |
|
- uses: actions/cache@v2
|
||||||
echo Add other actions to build,
|
with:
|
||||||
echo test, and deploy your project.
|
path: |
|
||||||
|
~/.gradle/caches
|
||||||
|
~/.gradle/wrapper
|
||||||
|
key: ${{ runner.os }}-gradle-${{ hashFiles('*.gradle.kts') }}
|
||||||
|
restore-keys: |
|
||||||
|
${{ runner.os }}-gradle-
|
||||||
|
- uses: gradle/wrapper-validation-action@v1.0.4
|
||||||
|
- name: Publish artifacts
|
||||||
|
run: >
|
||||||
|
./gradlew publishAllPublicationsToSpaceRepository --no-daemon --build-cache
|
||||||
|
-Ppublishing.space.user=${{ secrets.SPACE_APP_ID }}
|
||||||
|
-Ppublishing.space.token=${{ secrets.SPACE_APP_SECRET }}
|
||||||
|
1
gradle.properties
Normal file
1
gradle.properties
Normal file
@ -0,0 +1 @@
|
|||||||
|
kotlin.code.style=official
|
2
gradle/wrapper/gradle-wrapper.properties
vendored
2
gradle/wrapper/gradle-wrapper.properties
vendored
@ -1,5 +1,5 @@
|
|||||||
distributionBase=GRADLE_USER_HOME
|
distributionBase=GRADLE_USER_HOME
|
||||||
distributionPath=wrapper/dists
|
distributionPath=wrapper/dists
|
||||||
distributionUrl=https\://services.gradle.org/distributions/gradle-7.4-bin.zip
|
distributionUrl=https\://services.gradle.org/distributions/gradle-7.4.1-bin.zip
|
||||||
zipStoreBase=GRADLE_USER_HOME
|
zipStoreBase=GRADLE_USER_HOME
|
||||||
zipStorePath=wrapper/dists
|
zipStorePath=wrapper/dists
|
||||||
|
Loading…
Reference in New Issue
Block a user