aboutsummaryrefslogtreecommitdiff
path: root/trunk/lib
diff options
context:
space:
mode:
Diffstat (limited to 'trunk/lib')
-rw-r--r--trunk/lib/common.sh60
1 files changed, 31 insertions, 29 deletions
diff --git a/trunk/lib/common.sh b/trunk/lib/common.sh
index faeaeb4..66c2725 100644
--- a/trunk/lib/common.sh
+++ b/trunk/lib/common.sh
@@ -514,12 +514,13 @@ function svn_check {
cwd="`pwd`"
folder="`dirname $1`"
+ file="`basename $1`"
if [ -d "$folder/.svn" ]; then
cd $folder
- if [ "`svn status $1 | awk '{ print $1 }'`" == "?" ]; then
+ if [ "`svn status $file | awk '{ print $1 }'`" == "?" ]; then
return 1
else
return 0
@@ -623,6 +624,35 @@ function svn_mkdir {
}
+function su_svn {
+
+ # execute svn using a different user
+ if [ ! -z "$SVN_USER" ]; then
+ su $SVN_USER -c "svn $*"
+ else
+ svn $*
+ fi
+
+}
+
+function chown_svn {
+
+ # set svn folder ownership
+ if [ ! -z "$SVN_USER" ] && [ ! -z "$1" ]; then
+ chown -R $SVN_USER $1
+ fi
+
+}
+
+function chgrp_svn {
+
+ # set svn folder group
+ if [ ! -z "$SVN_GROUP" ] && [ ! -z "$1" ]; then
+ chgrp -R $SVN_GROUP $1
+ fi
+
+}
+
# -----------------------------------------------
# update jail functions
# -----------------------------------------------
@@ -1125,31 +1155,3 @@ function regexp_slash {
}
-function su_svn {
-
- # execute svn using a different user
- if [ ! -z "$SVN_USER" ]; then
- su $SVN_USER -c "svn $*"
- else
- svn $*
- fi
-
-}
-
-function chown_svn {
-
- # set svn folder ownership
- if [ ! -z "$SVN_USER" ] && [ ! -z "$1" ]; then
- chown -R $SVN_USER $1
- fi
-
-}
-
-function chgrp_svn {
-
- # set svn folder group
- if [ ! -z "$SVN_GROUP" ] && [ ! -z "$1" ]; then
- chgrp -R $SVN_GROUP $1
- fi
-
-}