3 # Print commands as they run
9 # Set 'release' mode if requested, influences commitid.sh
16 if [ "$arg" = "--release" ]
21 echo "Unrecognized argument '$arg'"
27 echo "Unrecognized argument '$arg'"
32 # Make sure the working copy and index are completely clean
33 git
diff --quiet --exit-code HEAD
35 # Emit a static indicator of the original commit
37 SRCBASE
=`pwd` .
/commitid.sh
42 # Stage all of the modified files
45 # Get an identifier for the current state of the code
46 object_id
=`git write-tree`
48 # Construct the target file/folder name
49 version
="charm-$(cat src/scripts/VERSION)"
51 # Generate the distribution tarball
52 git archive
--format=tar.gz
--prefix="$version/" -o $version.
tar.gz
$object_id
54 # And clean up the mess we made