diff --git a/ChangeLog b/ChangeLog index 676a20d..db1a7c1 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,6 @@ ??-??-????: enhancement: add rsync options: + "chmod", "chown", "copy_dirlinks", "existing", diff --git a/default-rsync.lua b/default-rsync.lua index 93f4add..9f65c1f 100644 --- a/default-rsync.lua +++ b/default-rsync.lua @@ -58,6 +58,7 @@ rsync.checkgauge = { bwlimit = true, checksum = true, chown = true, + chmod = true, compress = true, copy_dirlinks = true, copy_links = true, @@ -490,6 +491,12 @@ rsync.prepare = computedN = computedN + 1 end + if crsync.chmod + then + computed[ computedN ] = '--chmod=' .. crsync.chmod + computedN = computedN + 1 + end + if crsync.chown then computed[ computedN ] = '--chown=' .. crsync.chown diff --git a/default-rsyncssh.lua b/default-rsyncssh.lua index 290f622..cd01f70 100644 --- a/default-rsyncssh.lua +++ b/default-rsyncssh.lua @@ -15,15 +15,18 @@ -- -- -if not default then +if not default +then error( 'default not loaded' ); end -if not default.rsync then +if not default.rsync +then error( 'default.rsync not loaded' ); end -if default.rsyncssh then +if default.rsyncssh +then error( 'default-rsyncssh already loaded' ); end @@ -31,6 +34,7 @@ end -- rsyncssh extends default.rsync -- local rsyncssh = { default.rsync } + default.rsyncssh = rsyncssh --