]> git.saurik.com Git - wxWidgets.git/blobdiff - wxPython/distrib/makedemo
regened with new version
[wxWidgets.git] / wxPython / distrib / makedemo
index 3a41a18a566ee31792f2ae05c5e68ab7781f09a1..52bf91775bca11214f8362a735aa1af23ee48059 100755 (executable)
@@ -1,33 +1,35 @@
 #!/bin/bash
 #----------------------------------------------------------------------
 
 #!/bin/bash
 #----------------------------------------------------------------------
 
-if [ -z $1 ]; then
-    echo "Please specify a version number on the command line."
-    exit 1
-fi
-
 if [ ! -d wxPython ]; then
     echo "Please run this script from the root wxPython directory."
     exit 1
 fi
 
 if [ ! -d wxPython ]; then
     echo "Please run this script from the root wxPython directory."
     exit 1
 fi
 
+VERSION=`python -c "import setup;print setup.VERSION"`
+
 mkdir _distrib_tgz
 mkdir _distrib_tgz
-mkdir _distrib_tgz/wxPython-$1
+mkdir _distrib_tgz/wxPython-$VERSION
 
 
-cp -R demo _distrib_tgz/wxPython-$1
-cp -R samples _distrib_tgz/wxPython-$1
+cp -R demo _distrib_tgz/wxPython-$VERSION
+cp -R samples _distrib_tgz/wxPython-$VERSION
 
 # do some cleanup
 
 # do some cleanup
-rm -rf `find _distrib_tgz/wxPython-$1 -name CVS`
-rm -f `find  _distrib_tgz/wxPython-$1 -name "*.pyc"`
-rm -f `find  _distrib_tgz/wxPython-$1 -name .cvsignore`
-rm -f _distrib_tgz/wxPython-$1/demo/core
-rm -rf _distrib_tgz/wxPython-$1/demo/wxPython
+rm -rf `find _distrib_tgz/wxPython-$VERSION -name CVS`
+rm -f `find  _distrib_tgz/wxPython-$VERSION -name "*.pyc"`
+rm -f `find  _distrib_tgz/wxPython-$VERSION -name .cvsignore`
+rm -f `find  _distrib_tgz/wxPython-$VERSION -name "core.[0-9]*"`
+rm -f `find  _distrib_tgz/wxPython-$VERSION -name "core"`
+rm -f `find  _distrib_tgz/wxPython-$VERSION -name wxPython`
+rm -f `find  _distrib_tgz/wxPython-$VERSION -name "*.o"`
+rm -f `find  _distrib_tgz/wxPython-$VERSION -name "*.so"`
+rm -f `find  _distrib_tgz/wxPython-$VERSION -name "*~"`
+rm -f `find  _distrib_tgz/wxPython-$VERSION -name ".#*"`
 
 cd _distrib_tgz
 
 
 cd _distrib_tgz
 
-tar cvf ../dist/wxPython-demo-$1.tar wxPython-$1
-gzip ../dist/wxPython-demo-$1.tar
+tar cvf ../dist/wxPythonDemo-$VERSION.tar wxPython-$VERSION
+gzip -9 ../dist/wxPythonDemo-$VERSION.tar
 
 cd ..
 rm -r _distrib_tgz
 
 cd ..
 rm -r _distrib_tgz