Use build scan instead of --info --stacktrace (#1008)

So we can have much neater build logs
This commit is contained in:
Bo Zhang 2021-02-09 21:58:27 +08:00 committed by GitHub
parent 01374b1d32
commit d998b655e5
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 19 additions and 14 deletions

View File

@ -32,7 +32,7 @@ jobs:
run: chmod -R 777 *
- name: Init gradle project
run: ./gradlew clean --info
run: ./gradlew clean --scan
- name: Check keys
run: >
@ -46,31 +46,31 @@ jobs:
- name: fillBuildConstants
run: >
./gradlew
fillBuildConstants --info --stacktrace
fillBuildConstants --scan
-Dbintray_user=${{ secrets.BINTRAY_USER }} -Pbintray_user=${{ secrets.BINTRAY_USER }}
-Dbintray_key=${{ secrets.BINTRAY_KEY }} -Pbintray_key=${{ secrets.BINTRAY_KEY }}
- name: Assemble
run: ./gradlew assemble --info --stacktrace
run: ./gradlew assemble --scan
- name: Check
run: ./gradlew check --info --stacktrace
run: ./gradlew check --scan
- name: Gradle :mirai-core-utils:publish
run: >
./gradlew :mirai-core-utils:publish --info --stacktrace
./gradlew :mirai-core-utils:publish --scan
-Dbintray_user=${{ secrets.BINTRAY_USER }} -Pbintray_user=${{ secrets.BINTRAY_USER }}
-Dbintray_key=${{ secrets.BINTRAY_KEY }} -Pbintray_key=${{ secrets.BINTRAY_KEY }}
- name: Gradle :mirai-core-api:publish
run: >
./gradlew :mirai-core-api:publish --info --stacktrace
./gradlew :mirai-core-api:publish --scan
-Dbintray_user=${{ secrets.BINTRAY_USER }} -Pbintray_user=${{ secrets.BINTRAY_USER }}
-Dbintray_key=${{ secrets.BINTRAY_KEY }} -Pbintray_key=${{ secrets.BINTRAY_KEY }}
- name: Gradle :mirai-core:publish
run: >
./gradlew :mirai-core:publish --info --stacktrace
./gradlew :mirai-core:publish --scan
-Dbintray_user=${{ secrets.BINTRAY_USER }} -Pbintray_user=${{ secrets.BINTRAY_USER }}
-Dbintray_key=${{ secrets.BINTRAY_KEY }} -Pbintray_key=${{ secrets.BINTRAY_KEY }}
@ -118,6 +118,6 @@ jobs:
- name: Publish Gradle plugin
run: >
./gradlew
:mirai-console-gradle:publishPlugins --info --stacktrace
:mirai-console-gradle:publishPlugins --scan
-Dgradle.publish.key=${{ secrets.GRADLE_PUBLISH_KEY }} -Pgradle.publish.key=${{ secrets.GRADLE_PUBLISH_KEY }}
-Dgradle.publish.secret=${{ secrets.GRADLE_PUBLISH_SECRET }} -Pgradle.publish.secret=${{ secrets.GRADLE_PUBLISH_SECRET }}

View File

@ -19,13 +19,13 @@ jobs:
run: chmod -R 777 *
- name: Init gradle project
run: ./gradlew clean --info --stacktrace
run: ./gradlew clean --scan
- name: Build mirai-core series
run: ./gradlew assemble --info --stacktrace
run: ./gradlew assemble --scan
- name: mirai-core Tests
run: ./gradlew check --info --stacktrace
run: ./gradlew check --scan
build-all:
runs-on: ubuntu-latest
@ -45,10 +45,10 @@ jobs:
run: chmod -R 777 *
- name: Init gradle project
run: ./gradlew clean --info --stacktrace
run: ./gradlew clean --scan
- name: Build all
run: ./gradlew assemble --info --stacktrace
run: ./gradlew assemble --scan
- name: All Tests
run: ./gradlew check --info --stacktrace
run: ./gradlew check --scan

View File

@ -144,6 +144,11 @@ tasks.register("cleanExceptIntellij") {
}
}
extensions.findByName("buildScan")?.withGroovyBuilder {
setProperty("termsOfServiceUrl", "https://gradle.com/terms-of-service")
setProperty("termsOfServiceAgree", "yes")
}
fun Project.useIr() {
kotlinCompilations?.forEach { kotlinCompilation ->
kotlinCompilation.kotlinOptions.freeCompilerArgs += "-Xuse-ir"