gnome-mplayer-snapshot.sh 609 B

1234567891011121314151617181920212223242526272829
  1. #!/bin/bash
  2. set -e
  3. tmp=$(mktemp -d)
  4. trap cleanup EXIT
  5. cleanup() {
  6. set +e
  7. [ -z "$tmp" -o ! -d "$tmp" ] || rm -rf "$tmp"
  8. }
  9. unset CDPATH
  10. pwd=$(pwd)
  11. dirname=gnome-mplayer
  12. cd "$tmp"
  13. svn checkout http://gnome-mplayer.googlecode.com/svn/trunk/ $dirname
  14. cd $dirname
  15. eval `autoconf configure.in | egrep '^[[:blank:]]*VERSION='`
  16. REVISION=`LC_ALL=C svn info 2> /dev/null | grep Revision | cut -d' ' -f2`
  17. find . -type d -name .svn -print0 | xargs -0r rm -rf
  18. cd ..
  19. mv $dirname ${dirname}-${VERSION}
  20. tar jcf "$pwd"/${dirname}-${VERSION}.svn${REVISION}.tar.bz2 ${dirname}-${VERSION}
  21. cd ${pwd} >/dev/null
  22. exit