From 38cef641a5d2f6506615f5b8e0c5bfea32ef62f6 Mon Sep 17 00:00:00 2001 From: Wayne Davison Date: Tue, 4 Mar 2008 22:50:41 -0800 Subject: [PATCH] Updated rrsync to deal with the latest 3.0.0's use of the -e option. Added a couple more long options that might get passed. --- support/cull_options | 10 ++++++++-- support/rrsync | 5 ++++- 2 files changed, 12 insertions(+), 3 deletions(-) diff --git a/support/cull_options b/support/cull_options index c85a0363..3ef470df 100755 --- a/support/cull_options +++ b/support/cull_options @@ -4,13 +4,19 @@ # is included in the rrsync script. use strict; -our(%short_no_arg, %short_with_num, %long_opt); +our %short_no_arg; +our %short_with_num; +our %long_opt = ( + 'no-i-r' => 0, + 'fake-super' => 0, + 'log-file' => 3, +); our $last_long_opt; open(IN, '../options.c') or die "Unable to open ../options.c: $!\n"; while () { - if (/\Qargstr[x++]\E = '(.)'/) { + if (/\Qargstr[x++]\E = '([^.ie])'/) { $short_no_arg{$1} = 1; undef $last_long_opt; } elsif (/\Qasprintf(\E[^,]+, "-([a-zA-Z0-9])\%l?[ud]"/) { diff --git a/support/rrsync b/support/rrsync index e1ae6ec8..6e1a6eb8 100644 --- a/support/rrsync +++ b/support/rrsync @@ -74,6 +74,7 @@ our %long_opt = ( 'delete-during' => 0, 'delete-excluded' => 0, 'existing' => 0, + 'fake-super' => 0, 'files-from' => 3, 'force' => 0, 'from0' => 0, @@ -84,6 +85,7 @@ our %long_opt = ( 'inplace' => 0, 'link-dest' => 2, 'list-only' => 0, + 'log-file' => 3, 'log-format' => 1, 'max-delete' => 1, 'max-size' => 1, @@ -110,6 +112,7 @@ our %long_opt = ( 'super' => 0, 'temp-dir' => 2, 'timeout' => 1, + 'use-qsort' => 0, ); ### END of options data produced by the cull_options script. ### @@ -139,7 +142,7 @@ while ($command =~ /((?:[^\s\\]+|\\.[^\s\\]*)+)/g) { if ($_ eq '.') { $in_options = 0; } else { - next if /^-$short_no_arg+(e\d+\.\d+)?$/o || /^-$short_with_num\d+$/o; + next if /^-$short_no_arg+(e\d*\.\w*)?$/o || /^-$short_with_num\d+$/o; my($opt,$arg) = /^--([^=]+)(?:=(.*))?$/; my $disabled; -- 2.34.1