From 00c407cff9eb656fa4167308ad71a9034edf205b Mon Sep 17 00:00:00 2001 From: David Caldwell Date: Tue, 25 Aug 2009 01:46:37 -0700 Subject: [PATCH] [commit-partial] Keep the last few commit-partial patch files around. --- commit-patch | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/commit-patch b/commit-patch index 6737940..825f9aa 100755 --- a/commit-patch +++ b/commit-patch @@ -153,6 +153,11 @@ if ($commit_partial) { run([split(/ /,$vc{diff}), @ARGV], '>>', $patch); system(($ENV{VISUAL} || $ENV{EDITOR} || 'vi')." ".$patch); + my $last_patch = "#last-comit-partial.patch"; + unlink "$last_patch.3"; + rename "$last_patch.2", "$last_patch.3"; + rename "$last_patch", "$last_patch.2"; + link $patch, $last_patch; if (defined $message) { open PATCH, '<', $patch or die "couldn't read $patch: $!\n"; -- 2.51.2