Mercurial > hg > Members > kono > nitros9-code
changeset 3042:f3decf362611
Update burst script to use uploader's date and filename
author | Tormod Volden <debian.tormod@gmail.com> |
---|---|
date | Sat, 24 Jan 2015 00:00:18 +0100 |
parents | 7a78f43d97c1 |
children | 7f418362f640 |
files | scripts/burst |
diffstat | 1 files changed, 14 insertions(+), 7 deletions(-) [+] |
line wrap: on
line diff
--- a/scripts/burst Fri Jan 23 23:35:28 2015 +0100 +++ b/scripts/burst Sat Jan 24 00:00:18 2015 +0100 @@ -1,16 +1,23 @@ #!/bin/sh -e +NAME=$1 +TAG=$2 + HTDOCS=/home/project-web/nitros9/htdocs -TODAY=$(date +%Y%m%d) + +if [ -z "$TAG" ]; then + echo "$0: Missing name and date tag" + exit 1 +fi cd $HTDOCS -mkdir latest-$TODAY -cd latest-$TODAY -unzip -o ../nitros9project-$TODAY.zip +mkdir latest-$TAG +cd latest-$TAG +unzip -o ../$NAME-$TAG.zip echo "Options +Indexes" > .htaccess cd $HTDOCS rm latest -ln -s latest-$TODAY latest -rm nitros9project.zip -ln -s nitros9project-$TODAY.zip nitros9project.zip +ln -s latest-$TAG latest +rm $NAME.zip +ln -s $NAME-$TAG.zip $NAME.zip