|
|
|
@ -7,7 +7,7 @@ PROGRAM="osync" # Rsync based two way sync engine with fault tolerance
|
|
|
|
|
AUTHOR="(C) 2013-2019 by Orsiris de Jong"
|
|
|
|
|
CONTACT="http://www.netpower.fr/osync - ozy@netpower.fr"
|
|
|
|
|
PROGRAM_VERSION=1.3.0-prerc1
|
|
|
|
|
PROGRAM_BUILD=2019122401
|
|
|
|
|
PROGRAM_BUILD=2019122402
|
|
|
|
|
IS_STABLE=false
|
|
|
|
|
|
|
|
|
|
CONFIG_FILE_REVISION_REQUIRED=1.3.0
|
|
|
|
@ -1378,6 +1378,7 @@ function _deleteLocal {
|
|
|
|
|
# Apple BS mv does not keep ownership, simulating move
|
|
|
|
|
#mv -f "$replicaDir$files" "$replicaDir$deletionDir/$parentdir"
|
|
|
|
|
if [ -w "$replicaDir$files" ]; then
|
|
|
|
|
[ -f "$replicaDir$deletionDir/$parentdir/$files" ] && rm -f "$replicaDir$deletionDir/$parentdir/$files"
|
|
|
|
|
cp -p "$replicaDir$files" "$replicaDir$deletionDir/$parentdir" && rm -f "$replicaDir$files"
|
|
|
|
|
if [ $? -ne 0 ]; then
|
|
|
|
|
Logger "Cannot move \"$replicaDir$files\" => \"$replicaDir$deletionDir/$parentdir\"" "ERROR"
|
|
|
|
@ -1393,6 +1394,7 @@ function _deleteLocal {
|
|
|
|
|
# Apple BS mv does not keep ownership, simulating move
|
|
|
|
|
#mv -f "$replicaDir$files" "$replicaDir$deletionDir"
|
|
|
|
|
if [ -w "$replicaDir$files" ]; then
|
|
|
|
|
[ -f "$replicaDir$deletionDir/$files" ] && rm -f "$replicaDir$deletionDir/$files"
|
|
|
|
|
cp -p "$replicaDir$files" "$replicaDir$deletionDir/" && rm -f "$replicaDir$files"
|
|
|
|
|
if [ $? -ne 0 ]; then
|
|
|
|
|
Logger "Cannot move \"$replicaDir$files\" => \"$replicaDir$deletionDir\"" "ERROR"
|
|
|
|
@ -1539,6 +1541,7 @@ function _deleteRemoteSub {
|
|
|
|
|
mkdir -p "$REPLICA_DIR$DELETION_DIR/$parentdir"
|
|
|
|
|
# Apple BS mv does not keep ownership, simulating move
|
|
|
|
|
#mv -f "$REPLICA_DIR$files" "$REPLICA_DIR$DELETION_DIR/$parentdir"
|
|
|
|
|
[ -f "$REPLICA_DIR$DELETION_DIR/$parentdir/$files" ] && rm -f "$REPLICA_DIR$DELETION_DIR/$parentdir/$files"
|
|
|
|
|
if [ -w "$REPLICA_DIR$files" ]; then
|
|
|
|
|
cp -p "$REPLICA_DIR$files" "$REPLICA_DIR$DELETION_DIR/$parentdir/" && rm -f "$REPLICA_DIR$files"
|
|
|
|
|
if [ $? -ne 0 ]; then
|
|
|
|
@ -1553,6 +1556,7 @@ function _deleteRemoteSub {
|
|
|
|
|
RemoteLogger "Moving deleted file [$REPLICA_DIR$files] to [$REPLICA_DIR$DELETION_DIR] on $REPLICA_TYPE." "VERBOSE"
|
|
|
|
|
# Apple BS mv does not keep ownership, simulating move
|
|
|
|
|
#mv -f "$REPLICA_DIR$files" "$REPLICA_DIR$DELETION_DIR"
|
|
|
|
|
[ -f "$REPLICA_DIR$DELETION_DIR/$files" ] && rm -f "$REPLICA_DIR$DELETION_DIR/$files"
|
|
|
|
|
if [ -w "$REPLICA_DIR$files" ]; then
|
|
|
|
|
cp -p "$REPLICA_DIR$files" "$REPLICA_DIR$DELETION_DIR/" && rm -f "$REPLICA_DIR$files"
|
|
|
|
|
if [ $? -ne 0 ]; then
|
|
|
|
|