Created
November 25, 2015 20:31
-
-
Save ctubbsii/48a4e7c8e6bf39f7e83f to your computer and use it in GitHub Desktop.
A small script to find which file in a commit broke the maven build
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
for x in $(git diff --name-status $(git merge-base master HEAD) | arg2); do | |
echo $x | |
git clean -fdx > /dev/null && \ | |
git checkout $(git merge-base master HEAD) -- $x && \ | |
(mvn clean verify 2>&1 | tee ../log-$(echo $x | tr / _).txt > ../log-current.txt; [[ ${PIPESTATUS[0]} == 0 ]]) && \ | |
echo SUCCESS && \ | |
break || \ | |
echo FAILURE | |
done |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment