Skip to content

Commit

Permalink
Publish build scans for workflows validating the data capturing examples
Browse files Browse the repository at this point in the history
  • Loading branch information
etiennestuder committed Nov 19, 2022
1 parent 703db07 commit 741af30
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -45,11 +45,15 @@ jobs:
echo "apply from: file(\"../build-data-capturing-gradle-samples/${{matrix.sample-file}}\")" >> common-gradle-enterprise-gradle-configuration-groovy/build.gradle
- name: Run Gradle build using Groovy DSL
working-directory: common-gradle-enterprise-gradle-configuration-groovy
run: ./gradlew tasks
run: ./gradlew tasks -Dgradle.enterprise.url=https://ge.solutions-team.gradle.com
env:
GRADLE_ENTERPRISE_ACCESS_KEY: ${{ secrets.GE_SOLUTIONS_ACCESS_TOKEN }}
- name: Inject data capture script into Gradle build using Kotlin DSL
run: |
# apply sample file
echo "apply from: file(\"../build-data-capturing-gradle-samples/${{matrix.sample-file}}\")" >> common-gradle-enterprise-gradle-configuration-kotlin/build.gradle
- name: Run Gradle build using Kotlin DSL
working-directory: common-gradle-enterprise-gradle-configuration-kotlin
run: ./gradlew tasks
run: ./gradlew tasks -Dgradle.enterprise.url=https://ge.solutions-team.gradle.com
env:
GRADLE_ENTERPRISE_ACCESS_KEY: ${{ secrets.GE_SOLUTIONS_ACCESS_TOKEN }}
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,8 @@ jobs:
set -o pipefail
./mvnw -B clean verify -Dgradle.enterprise.url=https://ge.solutions-team.gradle.com -Dorg.slf4j.simpleLogger.log.gradle.goal.cache=debug 2>&1 | tee -a /tmp/gradle-build.log
echo "hasUnknownParams=$(grep "Build caching was not enabled for this goal execution because the following parameters were not handled" /tmp/gradle-build.log | wc -l)" >> $GITHUB_OUTPUT
env:
GRADLE_ENTERPRISE_ACCESS_KEY: ${{ secrets.GE_SOLUTIONS_ACCESS_TOKEN }}
- name: Fail if unmapped mojo parameters
run: exit 1
if: steps.mvn-build.outputs.hasUnknownParams != '0'
Original file line number Diff line number Diff line change
Expand Up @@ -43,8 +43,10 @@ jobs:
run: |
delimiter="$(openssl rand -hex 8)"
echo "mavenOutput<<${delimiter}" >> $GITHUB_OUTPUT
echo "$(mvn -f common-gradle-enterprise-maven-configuration/pom.xml -X --batch-mode clean validate -Dgradle.scan.disabled=true)" >> $GITHUB_OUTPUT
echo "$(mvn -f common-gradle-enterprise-maven-configuration/pom.xml -Dgradle.enterprise.url=https://ge.solutions-team.gradle.com -X --batch-mode clean validate -Dgradle.scan.disabled=true)" >> $GITHUB_OUTPUT
echo "${delimiter}" >> $GITHUB_OUTPUT
env:
GRADLE_ENTERPRISE_ACCESS_KEY: ${{ secrets.GE_SOLUTIONS_ACCESS_TOKEN }}
- name: Validate extension loaded
# Asserting that extension was loaded checking a log entry
run: exit 1
Expand Down

0 comments on commit 741af30

Please sign in to comment.