Skip to content

Commit eabcf8f

Browse files
authored
ci(bom): print full mvn-install.log on pre-install failure (#13891)
## Description Updates `java-cloud-bom/tests/pre-install.sh` to print the complete `mvn-install.log` on failure instead of truncating output with `tail -n 200`. ## Rationale When a module fails compilation during `pre-install.sh`, Maven skips installing its JAR into local cache (`~/.m2/repository`). Downstream modules subsequently fail dependency resolution when attempting to fetch missing in-repo SNAPSHOT artifacts from Maven Central. Because `pre-install.sh` previously ran `tail -n 200`, only the trailing downstream dependency resolution errors were printed in CI, concealing the actual root-cause compilation errors that occurred earlier in the log.
1 parent af18f65 commit eabcf8f

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

java-cloud-bom/tests/pre-install.sh

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -35,9 +35,9 @@ set -eo pipefail
3535

3636
if ! mvn install -pl $(cat bom_projects.txt) -am -amd -DskipTests=true -Dmaven.javadoc.skip=true -Dcheckstyle.skip=true -Denforcer.skip=true -Danimal.sniffer.skip=true -Dclirr.skip=true -Dgcloud.download.skip=true -B -V -T 1C -l java-cloud-bom/tests/mvn-install.log; then
3737
echo "========================================================================"
38-
echo "mvn install failed! Printing the last 200 lines of mvn-install.log:"
38+
echo "mvn install failed! Printing mvn-install.log:"
3939
echo "========================================================================"
40-
tail -n 200 java-cloud-bom/tests/mvn-install.log
40+
cat java-cloud-bom/tests/mvn-install.log
4141
exit 1
4242
fi
4343
rm bom_projects.txt

0 commit comments

Comments
 (0)