update_head $old_head, $new_head, "stitch: $prose";
}
+sub do_stitch ($) {
+ my ($prose) = @_;
+
+ my ($ffq_prev, $gdrlast, $ffq_prev_commitish) = ffq_prev_info();
+ if (!$ffq_prev_commitish) {
+ fail "No ffq-prev to stitch." unless $opt_noop_ok;
+ return;
+ }
+ my $dangling_head = get_head();
+
+ keycommits $dangling_head, \&snag, \&snag, \&snag;
+
+ stitch($dangling_head, $ffq_prev, $gdrlast, $ffq_prev_commitish, $prose);
+}
+
sub cmd_new_upstream_v0 () {
# automatically and unconditionally launders before rebasing
# if rebase --abort is used, laundering has still been done
my $prose = 'stitch';
GetOptions('prose=s', \$prose) or die badusage("bad options to stitch");
badusage "no arguments allowed" if @ARGV;
-
- my ($ffq_prev, $gdrlast, $ffq_prev_commitish) = ffq_prev_info();
- if (!$ffq_prev_commitish) {
- fail "No ffq-prev to stitch." unless $opt_noop_ok;
- return;
- }
- my $old_head = get_head();
-
- keycommits $old_head, \&snag, \&snag, \&snag;
-
- stitch($old_head, $ffq_prev, $gdrlast, $ffq_prev_commitish, $prose);
+ do_stitch($prose);
}
sub cmd_convert_from_gbp () {