implement checkoutSubversion()

This commit is contained in:
belliash 2012-01-08 18:55:12 +01:00
parent fd450c0c4a
commit 4344d60083
1 changed files with 17 additions and 0 deletions

View File

@ -17,3 +17,20 @@ function checkoutRsync() {
--exclude=/packages ${ADDRESS} ${DIRECTORY}" || return 1
return 0
}
#-------------------------------------------------------------------------------
# Downloads or updates specified SVN repository
# Parameters: %dest_directory% %address%
#-------------------------------------------------------------------------------
function checkoutSubversion() {
local DIRECTORY="${1}"
local ADDRESS="${2}"
if [ -d ${DIRECTORY} ]; then
cd ${DIRECTORY}
run "svn cleanup" || return 1
run "svn update" || return 1
else
run "svn checkout ${ADDRESS} ${DIRECTORY}" || return 1
fi
return 0
}