Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save jcfr/6029698 to your computer and use it in GitHub Desktop.
Save jcfr/6029698 to your computer and use it in GitHub Desktop.
#!/usr/bin/env bash
# Build and grep for failure output. Replace with your own command.
cd /Users/kitware/Dashboards/Nightly/Slicer-build/ITKv4-build
make -j8 || exit 125 # Try to build ITKv4, skip the commit if compilation failed
cd /Users/kitware/Dashboards/Nightly/Slicer/Slicer-build
make AffineRegistrationLib 2>&1 | grep 'internal compiler error'
# Retrieve the exit code of the grep.
if [ "$?" -eq "0" ]; then
# echo "Failed to compile AffineRegistrationLib - Internal compiler error :("
exit 1
else
# echo "AffineRegistrationLib compiled :)"
exit 0
fi
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment