Created
December 25, 2013 03:10
-
-
Save checko/8119870 to your computer and use it in GitHub Desktop.
nightly test 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
#!/bin/bash | |
cd /home/charles-chang | |
. .profile | |
# if exist, last build failed. do nothing. | |
cd nightly | |
if [ "$?" = "0" ]; then | |
exit 1 | |
fi | |
mkdir nightly | |
if [ "$?" -ne "0" ]; then | |
touch mkdirfail | |
exit 1 | |
fi | |
cd nightly | |
if [ "$?" -ne "0" ]; then | |
touch cdfail | |
exit 1 | |
fi | |
repo init -u git://robot/opensourcecsr/android-prima2/manifests/android.git -b speedsnail 2>&1 | tee repoinitlog | |
if [ "${PIPESTATUS[0]}" -ne "0" ]; then | |
touch repoinitfail | |
exit 1 | |
fi | |
repo sync 2>&1 | tee synclog | |
if [ "${PIPESTATUS[0]}" -ne "0" ]; then | |
touch syncfail | |
exit 1 | |
fi | |
make 2>&1 | tee log1 | |
if [ "${PIPESTATUS[0]}" -ne "0" ]; then | |
touch level1fail | |
exit 1 | |
fi | |
cd android | |
make showcommands update-api 2>&1 | tee log2.0 | |
if [ "${PIPESTATUS[0]}" -ne "0" ]; then | |
touch updateapifail | |
exit 1 | |
fi | |
make showcommands 2>&1 | tee log2 | |
if [ "${PIPESTATUS[0]}" -ne "0" ]; then | |
touch androidfaile | |
exit 1 | |
fi | |
cd .. | |
make android 2>&1 | tee log3 | |
if [ "${PIPESTATUS[0]}" -ne "0" ]; then | |
touch makeandroidfail | |
exit 1 | |
fi | |
echo Success! | |
mv log1 android/log2 log3 /home/charles-chang/ | |
cd ../ | |
rm -rf nightly |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment