mirror of
https://seed.radicle.dev/rad:z3gqcJUoA1n9HaHKufZs5FCSGazv5.git
synced 2026-11-28 21:50:26 +08:00
cli: Fix rad patch show with merged patches
We were not correctly calculating the base commit. Simply using the latest revision base does the job for now.
This commit is contained in:
@@ -30,9 +30,7 @@ fn show_patch_diff(patch: &patch::Patch, storage: &Repository) -> anyhow::Result
|
||||
}
|
||||
|
||||
fn patch_commits(patch: &patch::Patch, stored: &Repository) -> anyhow::Result<Vec<term::Line>> {
|
||||
let target_head = patch_merge_target_oid(patch.target(), stored)?;
|
||||
let base_oid = stored.raw().merge_base(target_head, **patch.head())?;
|
||||
let range = format!("{}..{}", base_oid, patch.head());
|
||||
let range = format!("{}..{}", patch.base(), patch.head());
|
||||
|
||||
let mut revwalk = stored.revwalk(*patch.head())?;
|
||||
let mut lines = Vec::new();
|
||||
|
||||
Reference in New Issue
Block a user