Sun, 10 Jul 2011 10:44:49 +0200
Modify icon to be square as most windowing systems expect icons to be.
michael@0 | 1 | ## |
michael@0 | 2 | ## release.sh -- Project Release Utility |
michael@0 | 3 | ## |
michael@0 | 4 | |
michael@0 | 5 | # Requires: GNU shtool |
michael@0 | 6 | # |
michael@0 | 7 | # Usage: ./release version |
michael@0 | 8 | # ./release tag |
michael@0 | 9 | # ./release dist |
michael@0 | 10 | # ./release upload |
michael@0 | 11 | |
michael@0 | 12 | version () { |
michael@0 | 13 | shtool version -l c -n "Europalab schachuhr" -p "schuhr_" -e version.cpp |
michael@0 | 14 | V=`shtool version -l c -d long version.cpp` |
michael@0 | 15 | sed -e "s/Version .*(.*)/Version $V/g" <docs/readme.txt >docs/readme.txt.n |
michael@0 | 16 | mv docs/readme.txt.n docs/readme.txt |
michael@0 | 17 | } |
michael@0 | 18 | |
michael@0 | 19 | tag () { |
michael@0 | 20 | V=`shtool version -l c -d short version.cpp | sed -e 's;\.;_;g'` |
michael@0 | 21 | echo "+++ tagging sources as SCHUR_${V}" |
michael@0 | 22 | hg tag SCHUR_${V} |
michael@0 | 23 | } |
michael@0 | 24 | |
michael@0 | 25 | dist () { |
michael@0 | 26 | echo "+++ cleaning" |
michael@0 | 27 | rm -f schachuhr-*.tar.gz |
michael@0 | 28 | echo "+++ configuring" |
michael@0 | 29 | qmake |
michael@0 | 30 | echo "+++ building" |
michael@0 | 31 | make clean all -j4 |
michael@0 | 32 | echo "+++ cleaning" |
michael@0 | 33 | make distclean >/dev/null 2>&1 |
michael@0 | 34 | echo "+++ fixing" |
michael@0 | 35 | shtool fixperm -v . |
michael@0 | 36 | echo "Please find . -exec grep myusername {}" |
michael@0 | 37 | echo "+++ rolling" |
michael@0 | 38 | V=`shtool version -l c -d short version.cpp` |
michael@0 | 39 | shtool tarball -o schachuhr-${V}.tar.gz -d schachuhr-${V} \ |
michael@0 | 40 | -e '\.hg,\.hgignore,\.[ao]$,^\.,*.tar.gz,^#.*,.*~$,*.bak' \ |
michael@0 | 41 | -e 'release\.sh,schuhr_stub.cpp,schuhr_stub.h,schuhr_scrap' \ |
michael@0 | 42 | -c 'gzip --best' . |
michael@0 | 43 | ls -l schachuhr-${V}.tar.gz |
michael@0 | 44 | echo "+++ testing" |
michael@0 | 45 | gunzip <schachuhr-${V}.tar.gz | tar tvf - | head -10 |
michael@0 | 46 | echo "[...]" |
michael@0 | 47 | gunzip <schachuhr-${V}.tar.gz | tar tvf - | tail -10 |
michael@0 | 48 | } |
michael@0 | 49 | |
michael@0 | 50 | upload () { |
michael@0 | 51 | echo "+++ copying to ftp://ftp.europalab.com/pub/sfw/schachuhr/" |
michael@0 | 52 | V=`shtool version -l c -d short version.cpp` |
michael@0 | 53 | scp schachuhr-${V}.tar.gz user@dev.host.tld:/z/schuhr/source/ |
michael@0 | 54 | } |