This commit is contained in:
Jephté Clain 2014-04-03 11:20:54 +04:00
parent 16a11c047f
commit 4e11b0f80f
2 changed files with 3 additions and 3 deletions

View File

@ -1 +1 @@
31
32

View File

@ -1446,10 +1446,10 @@ function cpnovcs() {
[ -d "$destdir" ] || mkdir -p "$destdir" || return 1
if progexists rsync; then
local gitexclude=/.git/
if [ "${src%/}" != "$src" ]; then
if [ "${src%/}" == "$src" ]; then
gitexclude="/$(basename -- "$src")$gitexclude"
fi
rsync -a ${__CPNOVCS_RSYNC_SLOW:+-c} --exclude CVS --exclude .svn --exclude "$gitexclude" "${__CPNOVCS_RSYNC_ARGS[@]}" "$src" "$destdir/"
rsync -a ${__CPNOVCS_RSYNC_SLOW:+-c} --exclude CVS/ --exclude .svn/ --exclude "$gitexclude" "${__CPNOVCS_RSYNC_ARGS[@]}" "$src" "$destdir/"
elif [ "${src%/}" != "$src" ]; then
__cpdir "$src" "$destdir"
else