Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #!/bin/bash
- source=~/Android/Source/CyanogenMod/Gingerbread
- vendor=htc
- board=mecha
- lunch=htc_mecha-eng
- done=update-cm-nightly-signed.zip
- filepath=~/Android/Nightlies/$board
- version=`ls -ltr $filepath/*.zip | awk '{ print $8 }' | tail -1 | sed "s/[^0-9]//g"`
- newversion=`expr $version + 1`
- file=cm_nightly_"$board"_full_KANG-$newversion.zip
- hostname=""
- username=""
- password=""
- remotedir=
- ## Commit the following out for testing:
- # Compile
- #cd $source
- #rm -r $source/device/$vendor/$board
- #sleep 5
- #repo sync
- #sleep 10
- #source build/envsetup.sh
- #lunch $lunch
- #sleep 5
- #make clean
- #sleep 5
- #make bacon -j`grep 'processor' /proc/cpuinfo | wc -l`
- #sleep 5
- # Move and rename file
- mv $source/out/target/product/$board/$done $filepath/$file
- cd $filepath
- md5sum $file > $file.md5sum
- # Upload file
- ftp -inv $hostname <<EOF
- user $username $password
- binary
- cd $remotedir
- put $file
- put $file.md5sum
- bye
- EOF
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement