[svk-commit] r2936 - trunk/lib/SVK/Command
nobody at bestpractical.com
nobody at bestpractical.com
Sat Jun 28 02:28:16 EDT 2008
Author: ruz
Date: Sat Jun 28 02:28:15 2008
New Revision: 2936
Modified:
trunk/lib/SVK/Command/Merge.pm
Log:
* on [s]merge save log into a file if -l is specified
Modified: trunk/lib/SVK/Command/Merge.pm
==============================================================================
--- trunk/lib/SVK/Command/Merge.pm (original)
+++ trunk/lib/SVK/Command/Merge.pm Sat Jun 28 02:28:15 2008
@@ -58,7 +58,7 @@
use SVK::Command::Log;
use SVK::Logger;
use SVK::Merge;
-use SVK::Util qw( get_buffer_from_editor traverse_history );
+use SVK::Util qw( get_buffer_from_editor traverse_history tmpfile );
sub options {
($_[0]->SUPER::options,
@@ -193,6 +193,7 @@
return;
}
+ # for checkouts we save later into a file
$self->get_commit_message ($self->{log} ? $merge->log(1) : undef)
unless $dst->isa('SVK::Path::Checkout');
@@ -242,6 +243,13 @@
$merge->run ($self->get_editor ($dst, undef, $self->{auto} ? $src : undef));
delete $self->{save_message};
}
+
+ if ( $self->{log} && $dst->isa('SVK::Path::Checkout') ) {
+ my ($fh, $file) = tmpfile ('commit', DIR => '', TEXT => 1, UNLINK => 0);
+ print $fh $merge->log(1);
+ $logger->warn(loc ("Log message saved in %1.", $file));
+ }
+
return;
}
More information about the svk-commit
mailing list