@@ -43,16 +43,15 @@ inputs:
4343outputs :
4444 buildScanFirstBuild :
4545 description : " First build scan url"
46- value : ${{ steps.run .outputs.buildScanFirstBuild }}
46+ value : ${{ steps.summary .outputs.buildScanFirstBuild }}
4747 buildScanSecondBuild :
4848 description : " Second build scan url"
49- value : ${{ steps.run .outputs.buildScanSecondBuild }}
49+ value : ${{ steps.summary .outputs.buildScanSecondBuild }}
5050
5151runs :
5252 using : " composite"
5353 steps :
5454 - name : Run Gradle Experiment 3
55- id : run
5655 run : |
5756 # Read the action inputs
5857 ARG_GIT_REPO=""
@@ -105,9 +104,6 @@ runs:
105104 # Navigate into the folder containing the validation scripts
106105 cd develocity-gradle-build-validation
107106
108- # Do not exit on error to allow post-actions
109- set +e
110-
111107 # Run the experiment
112108 ./03-validate-local-build-caching-different-locations.sh \
113109 ${ARG_GIT_REPO:+"-r" "$ARG_GIT_REPO"} \
@@ -121,16 +117,6 @@ runs:
121117 ${ARG_DEVELOCITY_ENABLE:+"-e"} \
122118 ${ARG_FAIL_IF_NOT_FULLY_CACHEABLE:+"-f"} \
123119 ${RUNNER_DEBUG:+"--debug"}
124- EXPERIMENT_EXIT_CODE=$?
125-
126- # Set the Build Scan urls as outputs
127- BUILD_SCAN_1=$(grep -m 1 "first build" ${RECEIPT_FILE} | sed 's/.* //')
128- BUILD_SCAN_2=$(grep -m 1 "second build" ${RECEIPT_FILE} | sed 's/.* //')
129-
130- echo "buildScanFirstBuild=$BUILD_SCAN_1" >> $GITHUB_OUTPUT
131- echo "buildScanSecondBuild=$BUILD_SCAN_2" >> $GITHUB_OUTPUT
132-
133- exit $EXPERIMENT_EXIT_CODE
134120 shell : bash
135121 - name : Archive receipt
136122 id : upload-artifact
@@ -139,13 +125,21 @@ runs:
139125 with :
140126 name : experiment-3-receipt-${{ github.job }}${{ strategy.job-total > 1 && format('-{0}', strategy.job-index) || '' }}
141127 path : develocity-gradle-build-validation/.data/03-validate-local-build-caching-different-locations/latest/exp3-*.receipt
142- - name : Fill GitHub summary
128+ - name : Fill GitHub summary and outputs
129+ id : summary
143130 if : always()
144131 run : |
145132 RECEIPT_FILE="develocity-gradle-build-validation/.data/03-validate-local-build-caching-different-locations/latest/exp3-*.receipt"
146133 if [ -f ${RECEIPT_FILE} ]; then
147134 cat ${RECEIPT_FILE} >> $GITHUB_STEP_SUMMARY
148135 echo "-------------" >> $GITHUB_STEP_SUMMARY
149136 echo "Download receipt: ${{ steps.upload-artifact.outputs.artifact-url }}" >> $GITHUB_STEP_SUMMARY
137+
138+ # Set the Build Scan urls as outputs
139+ BUILD_SCAN_1=$(grep -m 1 "first build" ${RECEIPT_FILE} | grep -o 'http.\S\+')
140+ BUILD_SCAN_2=$(grep -m 1 "second build" ${RECEIPT_FILE} | grep -o 'http.\S\+')
141+
142+ echo "buildScanFirstBuild=$BUILD_SCAN_1" >> $GITHUB_OUTPUT
143+ echo "buildScanSecondBuild=$BUILD_SCAN_2" >> $GITHUB_OUTPUT
150144 fi
151145 shell : bash
0 commit comments