这是我的脚本...我在下面收到此错误。我怀疑第二个如果其他错误但无法弄清楚..
read -p "Do you wish to continue the merge session? (y/n) " RESP
if [ "$RESP" = "y" ]; then
co_repo=`echo $target_url | cut -d "/" -f 7`
co_workspace="svn_promote_$co_repo"
echo "$co_workspace ................................................."
if [-d "$co_workspace" ] then;
echo -e "Creating target workspace $co_workspace"
echo -e ""
mkdir $co_workspace
echo -e "Checking out $target_url .."
svn co $target_url $co_workspace
else
echo -e "Target workspace exists. Updating ..."
svn update $co_workspace
fi
else
echo "Exiting promote session .."
fi
错误:
monday_try.sh: line 44: syntax error near unexpected token `else'
monday_try.sh: line 44: ` else'