Skip to content

Commit

Permalink
build: change build
Browse files Browse the repository at this point in the history
  • Loading branch information
CoolLoong committed Mar 11, 2024
1 parent d70f2b3 commit 03f8558
Show file tree
Hide file tree
Showing 2 changed files with 28 additions and 4 deletions.
21 changes: 17 additions & 4 deletions .github/workflows/gradle.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,21 +2,34 @@ name: Java CI with Gradle

on:
push:
branches: [ "master" ]
branches: [ "master", "action" ]
pull_request:
branches: [ "master" ]
branches: [ "master", "action" ]

jobs:
build:
runs-on: ubuntu-latest
steps:
# support for ipv6
- name: Set up WARP
uses: fscarmen/[email protected]
with:
stack: dual
- uses: actions/checkout@v4
- run: chmod +x gradlew
- uses: actions/setup-java@v4
with:
java-version: '21'
distribution: 'graalvm'
cache: 'gradle'
- run: gradle build
- name: Setup Gradle
uses: gradle/gradle-build-action@v3
with:
gradle-version: wrapper
cache-overwrite-existing: true
build-scan-publish: true
build-scan-terms-of-service-url: "https://gradle.com/terms-of-service"
build-scan-terms-of-service-agree: "yes"
arguments: build --scan
- name: Upload Allay-API
uses: actions/upload-artifact@v4
if: success()
Expand Down
11 changes: 11 additions & 0 deletions build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,10 @@ tasks.register<DefaultTask>("buildFast") {
group = "alpha build"
}

tasks.register<DefaultTask>("buildForGithubAction") {
group = "alpha build"
}

tasks.build {
group = "alpha build"
}
Expand Down Expand Up @@ -103,6 +107,13 @@ subprojects {
tasks["check"].enabled = false
}

tasks.register<DefaultTask>("buildForGithubAction") {
dependsOn(tasks.build)
group = "alpha build"
tasks["javadoc"].enabled = false
tasks["javadocJar"].enabled = false
}

tasks.build {
group = "alpha build"
dependsOn("shadowJar")
Expand Down

0 comments on commit 03f8558

Please sign in to comment.