Subversion Repositories ipe_artfile_utils

Compare Revisions

No changes between revisions

Regard whitespace Rev 3 → Rev 2

/trunk/build_stable
0,0 → 1,25
#!/bin/bash
 
# Get the directory of this script (also works with symlinks)
# http://stackoverflow.com/questions/59895/can-a-bash-script-tell-what-directory-its-stored-in
SOURCE="${BASH_SOURCE[0]}"
while [ -h "$SOURCE" ]; do # resolve $SOURCE until the file is no longer a symlink
DIR="$( cd -P "$( dirname "$SOURCE" )" && pwd )"
SOURCE="$(readlink "$SOURCE")"
[[ $SOURCE != /* ]] && SOURCE="$DIR/$SOURCE" # if $SOURCE was a relative symlink, we need to resolve it relative to the path where the symlink file was located
done
DIR="$( cd -P "$( dirname "$SOURCE" )" && pwd )"
 
cd "$DIR"
dirname=$( basename "$( pwd )" )
tmpfile=$( mktemp )
 
FILENAME="stable.tar.gz"
 
cd ..
tar cvfz "$tmpfile" --exclude="$dirname"/"$FILENAME" --exclude ".svn" -- "$dirname"
 
# otherwise: "the file has changed while reading"
mv "$tmpfile" "$dirname"/"$FILENAME"
 
chmod 644 "$dirname"/"$FILENAME"
Property changes:
Added: svn:executable
+*
\ No newline at end of property
/trunk/stable.tar.gz
Cannot display: file marked as a binary type.
svn:mime-type = application/gzip
Property changes:
Added: svn:mime-type
+application/gzip
\ No newline at end of property