Created
March 13, 2013 20:50
-
-
Save fitzgen/5156022 to your computer and use it in GitHub Desktop.
This file contains hidden or 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
| #!/usr/bin/env bash | |
| set -e | |
| function errorAndExit { | |
| echo "Error building, see '.build-error.log' file" | |
| say "Error! Error! Error!" | |
| exit 1 | |
| } | |
| if [ -e "`pwd`/.git" ]; then | |
| OBJ="obj-`git rev-parse --abbrev-ref HEAD`" | |
| else | |
| OBJ="obj" | |
| fi | |
| if [[ -d $OBJ ]]; then | |
| make -C $OBJ/browser/devtools &> .build-error.log || errorAndExit | |
| make -C $OBJ/toolkit/devtools &> .build-error.log || errorAndExit | |
| make -C $OBJ/browser/app &> .build-error.log || errorAndExit | |
| else | |
| ./mach build &> .build-error.log || errorAndExit | |
| # Only say things if this is going to be a long build, we might be alt | |
| # tabbed. | |
| say "Successfully finished building." | |
| fi | |
| # Since we got this far without exiting, there weren't any errors and we can | |
| # delete the log. | |
| rm .build-error.log | |
| echo | |
| echo "# To Run:" | |
| echo "./$OBJ/dist/Nightly.app/Contents/MacOS/firefox-bin -P Nightly" | |
| echo "# XPC shell tests:" | |
| echo "./mach xpcshell-test toolkit/devtools/debugger/tests/unit" | |
| echo "# Mochitests:" | |
| echo "make TEST_PATH=browser/devtools/debugger/test/ -C $OBJ mochitest-browser-chrome | grep -v SCREENSHOT | grep -v 'JavaScript Warning'" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment