summaryrefslogtreecommitdiff
path: root/tool/release.sh
diff options
context:
space:
mode:
authornaruse <naruse@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2013-12-25 15:43:36 +0000
committernaruse <naruse@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2013-12-25 15:43:36 +0000
commit934546eb0b8c17bfe2364084d7181a8e1ce205b4 (patch)
tree0da6520e1a0aeb196764b72a2b627e675123a17e /tool/release.sh
parent31b4980ef66caa78a97fee4a2050677be7db966d (diff)
add release script on ftp.r-l.o
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@44423 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'tool/release.sh')
-rw-r--r--tool/release.sh35
1 files changed, 35 insertions, 0 deletions
diff --git a/tool/release.sh b/tool/release.sh
new file mode 100644
index 0000000..08f1502
--- /dev/null
+++ b/tool/release.sh
@@ -0,0 +1,35 @@
+#!/bin/sh
+
+RUBYDIR=/home/ftp/pub/ruby
+
+releases=`ls ruby-*|grep -o 'ruby-[0-9]\.[0-9]\.[0-9]\(-\(preview\|rc\|p\)[0-9]\{1,4\}\)\?'|uniq`
+
+# check files
+for r in $releases
+do
+ echo "checking files for $r..."
+ if ! [ -f $r.tar.gz ];then
+ echo "ERROR: $r.tar.gz not found"
+ exit 1
+ elif ! [ -f $r.tar.bz2 ];then
+ echo "ERROR: $r.tar.bz2 not found"
+ exit 1
+ elif ! [ -f $r.zip ];then
+ echo "ERROR: $r.zip not found"
+ exit 1
+ else
+ echo "files are ok"
+ fi
+done
+
+# version directory
+for r in $releases
+do
+ xy=`echo $r|grep -o '[0-9]\.[0-9]'`
+ dir="${RUBYDIR}/$xy"
+ echo "$dir"
+ mkdir -p $dir
+ cp $r.tar.gz $dir/$r.tar.gz
+ cp $r.tar.bz2 $dir/$r.tar.bz2
+ cp $r.zip $dir/$r.zip
+done