Skip to content

Commit

Permalink
Fancy fast forward
Browse files Browse the repository at this point in the history
  • Loading branch information
Caleb-T-Owens authored and mtsgrd committed Sep 4, 2024
1 parent 924cc5d commit e4834db
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions crates/gitbutler-repo/src/rebase.rs
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,10 @@ pub fn cherry_rebase_group(
|head, to_rebase| {
let head = head?;

if to_rebase.parent_ids().len() == 1 && head.id() == to_rebase.parent_id(0)? {
return Ok(to_rebase);
};

let cherrypick_index = repository
.cherry_pick_gitbutler(&head, &to_rebase, None)
.context("failed to cherry pick")?;
Expand Down

0 comments on commit e4834db

Please sign in to comment.