3 #### Settings, feel free to adjust these as required ####
6 NAME
="shindig-${VERSION}"
9 #### Build a clean php-shindig tarball
11 echo "Creating $NAME release files"
13 # remove any old work that may have remained
14 echo " Removing old temp directory and files.."
16 rm -rf $NAME.
tar.gz
$NAME.
zip $NAME.
tar.bz2
18 # create temp dir and copy files from current path
19 echo " Creating new structure, copying php, features and samples files.."
22 cp -r ..
/features
/tmp
/$NAME/
23 cp -r ..
/javascript
/tmp
/$NAME
24 cp .htaccess
/tmp
/$NAME
25 cp ..
/{COMMITTERS
,COPYING
,DISCLAIMER
,LICENSE
,NOTICE
} /tmp
/$NAME
26 cp ..
/config
/{oauth.json
,container.js
} /tmp
/$NAME/config
/
29 # remove those pesky .svn directories
30 echo " Removing unwanted files"
31 rm -f *.gz
*.bz2
*.
zip make-release.sh
32 find .
-name ".svn" -exec rm -rf {} \
; &>/dev
/null
33 find .
-name "pom.xml" -exec rm -f {} \
; &>/dev
/null
35 # and rewrite the container.php file to use the different release file paths (features/ instead of ../features, etc)
36 echo " Rewriting default configuration to release structure"
38 cat container.php |
sed "s/\/..\/..\//\/..\//" > container.php.new
39 mv container.php.new container.php
41 # and create the final tar.gz, tar.bz2 and .zip files
43 echo " Creating $OPWD/$NAME.tar.gz"
44 tar c
$NAME |
gzip > $OPWD/$NAME.
tar.gz
45 echo " Creating $OPWD/$NAME.tar.bz2"
46 tar c
$NAME |
bzip2 > $OPWD/$NAME.
tar.bz2
47 echo " Creating $OPWD/$NAME.zip"
48 zip -r $OPWD/$NAME.
zip $NAME &>/dev
/null
50 echo " Removing temp files"