summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorruki <[email protected]>2019-08-22 23:22:56 +0800
committerruki <[email protected]>2019-08-22 14:17:41 +0800
commit2f5eda680a0c7e2bce5e6d88d879ced3ca2e2751 (patch)
tree735638f1dc589def32919e732c6d7bffc6f0e97f
parent8447b5719e117c115e594d55d8e9b59fe6773bf5 (diff)
add archive-all.sh
-rwxr-xr-xscripts/archive-all.sh18
1 files changed, 18 insertions, 0 deletions
diff --git a/scripts/archive-all.sh b/scripts/archive-all.sh
new file mode 100755
index 000000000..287052a6b
--- /dev/null
+++ b/scripts/archive-all.sh
@@ -0,0 +1,18 @@
+#!/usr/bin/env bash
+
+# ./scripts/archive-all.sh v2.2.7
+tag=$1
+format="tar.gz"
+projectdir=/tmp/.xmake_archive
+outputfile=`pwd`/xmake-$tag.$format
+if [ -d $projectdir ]; then
+ rm -rf $projectdir
+fi
+git clone --depth=1 -b "$tag" "https://github.com/xmake-io/xmake.git" --recursive $projectdir
+cd $projectdir
+rm -rf tests
+git add .
+git commit -a -m "..."
+git tag "$tag-1"
+git archive --format $format -o $outputfile "$tag-1"
+shasum -a 256 $outputfile