From b208d5006ad6133f3df3a89fbe7795b28c904e32 Mon Sep 17 00:00:00 2001 From: David Caldwell Date: Wed, 15 May 2013 10:53:16 -0700 Subject: [PATCH] [commit-patch] Use --force when patching back to the clean version so if something goes wrong it doesn't ask interactive questions. --- commit-patch | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/commit-patch b/commit-patch index 1df3a11..654a372 100755 --- a/commit-patch +++ b/commit-patch @@ -237,7 +237,7 @@ run([split(/ /,$vc{diff}), @changed, @removed], '>', \$working_patch, unless ($working_patch =~ /^\s*$/s) { # Work around an apparent bug in darcs () run(["interdiff", $vc{patcharg}, $patch, '/dev/stdin'], '<', \$working_patch, '>', \$non_committed_patch, '2>', \$err) or die "$err\n"; - run(["patch", $vc{patcharg}, "-R"], '<', \$working_patch, '>', \$out, '2>', \$err) or die "$out\n$err\n"; + run([qw"patch -R --force", $vc{patcharg}], '<', \$working_patch, '>', \$out, '2>', \$err) or die "$out\n$err\n"; } run(["patch", $vc{patcharg}], '<', $patch, '>', \$out, '2>', \$err) or die "patch: $out\n$err\n"; run([split(/ /,$vc{add}), @added], '>', \$out, '2>', \$err) or die "$vc{add}: $out\n$err\n" if @added; -- 2.51.2