BugFix: sudo choose

This commit is contained in:
Dirk Alders 2021-01-17 18:50:49 +01:00
parent b0b417fd57
commit be3dda31de

2
mysync
View File

@ -68,7 +68,7 @@ def rsync_command(**kwargs):
if localpath is not None: if localpath is not None:
remotepath = path_filter(kwargs.get(PROP_REMOTE)) remotepath = path_filter(kwargs.get(PROP_REMOTE))
skip = kwargs.get(PROP_SKIP) skip = kwargs.get(PROP_SKIP)
if remotepath.find('@') != -1: if remotepath.find('root@') != -1:
cmd_l = ['rsync', '-avn' if DEBUG else '-av', '--delete', remotepath, localpath] cmd_l = ['rsync', '-avn' if DEBUG else '-av', '--delete', remotepath, localpath]
else: else:
cmd_l = ['rsync', '-avn' if DEBUG else '-av', '--delete', '--rsync-path="%s"' % RSYNC_REMOTE_COMMAND, remotepath, localpath] cmd_l = ['rsync', '-avn' if DEBUG else '-av', '--delete', '--rsync-path="%s"' % RSYNC_REMOTE_COMMAND, remotepath, localpath]