Add packaging script
authorHugo Villeneuve <hugo@hugovil.com>
Thu, 8 Sep 2011 04:05:16 +0000 (00:05 -0400)
committerHugo Villeneuve <hugo@hugovil.com>
Wed, 26 Mar 2014 22:53:53 +0000 (18:53 -0400)
Add list of files to exclude in git export

.gitattributes [new file with mode: 0644]
package.sh [new file with mode: 0755]

diff --git a/.gitattributes b/.gitattributes
new file mode 100644 (file)
index 0000000..54523fe
--- /dev/null
@@ -0,0 +1,3 @@
+.gitattributes export-ignore
+.gitignore export-ignore
+package.sh export-ignore
diff --git a/package.sh b/package.sh
new file mode 100755 (executable)
index 0000000..1109479
--- /dev/null
@@ -0,0 +1,23 @@
+#!/bin/bash
+
+PACKAGE="grip-3.4.0"
+
+# Create temporary export archive
+git archive --format=tar --prefix=${PACKAGE}/ master | bzip2 -9 > ${PACKAGE}-git.tar.bz2
+
+# Generate autoconf files for distribution
+tar -xvf ${PACKAGE}-git.tar.bz2
+cd ${PACKAGE}
+./autogen.sh
+
+# Generate translation files (po)
+./configure
+make -C po
+make distclean
+
+cd ../
+tar cvf - ${PACKAGE} | bzip2 -9 > ${PACKAGE}.tar.bz2
+
+# Cleanup
+rm -rf ${PACKAGE}
+rm -f ${PACKAGE}-git.tar.bz2