sym
This commit is contained in:
23
publish
23
publish
@@ -4,21 +4,10 @@ SDIR=$(cd "$(dirname "$0")" ; pwd -P)
|
|||||||
DBG_DIR=/var/www/dbg
|
DBG_DIR=/var/www/dbg
|
||||||
DST_DIR=/var/www/html
|
DST_DIR=/var/www/html
|
||||||
|
|
||||||
rsync -aivc --delete $DBG_DIR
|
# Copy dbg to prod
|
||||||
|
rsync -aivc --delete $DBG_DIR $DST_DIR
|
||||||
|
|
||||||
|
# Symlink
|
||||||
$CONNECT_SRC_DIR/Utilities/ucim-spm/local/ivac $DST_DIR/Modules
|
cd $DST_DIR
|
||||||
|
ln -s ../cbr
|
||||||
# Find out the latest commit in the whole repo
|
ln -s ../dbg
|
||||||
#git branch -av --sort=-committerdate
|
|
||||||
#git branch -av --sort=-committerdate | tr -s ' ' | head -n1
|
|
||||||
cmt=`git branch -av --sort=-committerdate | tr -s ' ' | head -n1 | cut -d' ' -f3`
|
|
||||||
echo "Latest commit: $cmt"
|
|
||||||
|
|
||||||
# Switch to the latest commit
|
|
||||||
git checkout -f $cmt
|
|
||||||
|
|
||||||
# Copy dist
|
|
||||||
mkdir -p $DST_DIR
|
|
||||||
rm -fR $DST_DIR/*
|
|
||||||
cp -R dist/* $DST_DIR
|
|
||||||
|
|||||||
Reference in New Issue
Block a user