PageRenderTime 124ms CodeModel.GetById 0ms RepoModel.GetById 0ms app.codeStats 0ms

/autoMokoRelease.sh

http://android-on-freerunner.googlecode.com/
Shell | 35 lines | 30 code | 2 blank | 3 comment | 3 complexity | 0b8a458a012a958aa92dbb14ea896c14 MD5 | raw file
  1. #!/bin/bash
  2. BUILD_ROOT="" #Path from / to the directory where you have checked out the repo.
  3. PROJECT="android-on-freerunner" #Google code project
  4. USER="" #Google code user name without @gmail.com
  5. PASSWORD="" #Google code password not you gmail password can be found here:
  6. #http://code.google.com/hosting/settings
  7. ANDROID_VERSION="Cupcake" #version for lables
  8. LABELS="Type-Archive, BuildVersion-Weekly" #Labels
  9. SUMMARY="Weekly realease of andoid-on-freerunner." #Summary "Buildt on: YYYY-MM-DD" will be added to this.
  10. FILENAME="android-on-freerunner-cupcake-week" #Filename "-YYYY-WW" will be added to the end, after this
  11. #.zip or .tar.gz will be added
  12. LABELS=$LABELS", AndroidVersion-$ANDROID_VERSION"
  13. SUMMARY=$SUMMARY" Buildt on: "$(date +%Y-%m-%d)
  14. FILENAME=$FILENAME"-"$(date +%Y-%V)
  15. cd $BUILD_ROOT
  16. repo sync
  17. make TARGET_PRODUCT=freerunner
  18. rm -rf weeklyBuild
  19. mkdir weeklyBuild
  20. cp -R baseDir/* weeklyBuild/
  21. cp out/target/product/freerunner/*.img weeklyBuild/
  22. md5sum weeklyBuild/boot/uImage-GTA02.bin weeklyBuild/ramdisk.img weeklyBuild/uImage weeklyBuild/userdata.img weeklyBuild/kernel.img weeklyBuild/qi.img weeklyBuild/system.img weeklyBuild/uImage.bin > weeklyBuild/md5sums
  23. cd weeklyBuild
  24. TRIES=0
  25. while [[ $? != 0 && $TRIES < 5 ]] #Retry the buggy zip command 5 times hope that it works one of the times....
  26. do
  27. let TRIES=TRIES+1
  28. zip -r ../$FILENAME . #Bugged out zip command!!!!!!!!
  29. done
  30. cd ..
  31. tar -czvf $FILENAME.tar.gz weeklyBuild/*
  32. ./googlecode_upload.py -s "$SUMMARY" -p $PROJECT -u $USER -w $PASSWORD -l "$LABELS, OpSys-Windows" $FILENAME.zip
  33. ./googlecode_upload.py -s "$SUMMARY" -p $PROJECT -u $USER -w $PASSWORD -l "$LABELS, OpSys-Linux" $FILENAME.tar.gz