In perl.git, the branch blead has been updated <http://perl5.git.perl.org/perl.git/commitdiff/0d083db364216f828907c1016507e100d0103f9c?hp=813fcdee40ed61472236553cef309e133e8c4775>
- Log ----------------------------------------------------------------- commit 0d083db364216f828907c1016507e100d0103f9c Author: David Golden <[email protected]> Date: Tue Jun 29 21:28:24 2010 -0400 Improve git-deltatool UI and support cherrymaint Allows going 'back' from a section submenu to the main menu for each commit. Adds support for calling Porting/cherrymaint to recommend cherrypicking while reviewing commits for perldelta. One must recommend cherrymaint before specifying other actions in either the assign or review modes. This is hack-ish, but should work well enough to capture cherrymaint nominations while the release manager is reviewing commits anyway. ----------------------------------------------------------------------- Summary of changes: Porting/git-deltatool | 25 ++++++++++++++++++++++++- 1 files changed, 24 insertions(+), 1 deletions(-) diff --git a/Porting/git-deltatool b/Porting/git-deltatool index 8ab7c80..ac35441 100755 --- a/Porting/git-deltatool +++ b/Porting/git-deltatool @@ -9,6 +9,7 @@ use warnings; package Git::DeltaTool; use Class::Struct; +use File::Basename; use File::Temp; use Getopt::Long; use Git::Wrapper; @@ -343,6 +344,15 @@ sub y_n { # handlers #--------------------------------------------------------------------------# +sub do_cherry { + my ($self, $choice, $log) = @_; + my $id = $log->short_id; + $self->y_n("Recommend a cherry pick of '$id' to maint?") or return; + my $cherrymaint = dirname($0) . "/cherrymaint"; + system("$^X $cherrymaint --vote $id"); + return; # false will re-prompt the same commit +} + sub do_done { my ($self, $choice, $log) = @_; my $note = $log->notes; @@ -444,6 +454,8 @@ sub do_platform { sub do_quit { exit 0 } +sub do_repeat { return 0 } + sub do_skip { return 1 } sub do_special { @@ -471,8 +483,9 @@ HERE sub do_subsection { my ($self, $choice, $log) = @_; + my @choices = ( $choice->{subsection}, $self->submenu_choices ); say "For " . _strip_parens($choice->{name}) . ":"; - return $self->dispatch( $self->prompt( $choice->{subsection} ), $log); + return $self->dispatch( $self->prompt( @choices ), $log); } #--------------------------------------------------------------------------# @@ -482,12 +495,22 @@ sub do_subsection { sub action_choices { my ($self) = @_; state $action_choices = [ + { name => '(+)Cherrymaint', handler => 'cherry' }, { name => 'S(k)ip', handler => 'skip' }, { name => '(Q)uit', handler => 'quit' }, ]; return $action_choices; } +sub submenu_choices { + my ($self) = @_; + state $submenu_choices = [ + { name => '(B)ack', handler => 'repeat' }, + ]; + return $submenu_choices; +} + + sub review_choices { my ($self) = @_; state $action_choices = [ -- Perl5 Master Repository
