Merge branch 'pw/rebase-keep-base-fixes'
"git rebase --keep-base" used to discard the commits that are already cherry-picked to the upstream, even when "keep-base" meant that the base, on top of which the history is being rebuilt, does not yet include these cherry-picked commits. The --keep-base option now implies --reapply-cherry-picks and --no-fork-point options. * pw/rebase-keep-base-fixes: rebase --keep-base: imply --no-fork-point rebase --keep-base: imply --reapply-cherry-picks rebase: factor out branch_base calculation rebase: rename merge_base to branch_base rebase: store orig_head as a commit rebase: be stricter when reading state files containing oids t3416: set $EDITOR in subshell t3416: tighten two tests
This commit is contained in:
8
commit.c
8
commit.c
@ -59,6 +59,14 @@ struct commit *lookup_commit_or_die(const struct object_id *oid, const char *ref
|
||||
return c;
|
||||
}
|
||||
|
||||
struct commit *lookup_commit_object(struct repository *r,
|
||||
const struct object_id *oid)
|
||||
{
|
||||
struct object *obj = parse_object(r, oid);
|
||||
return obj ? object_as_type(obj, OBJ_COMMIT, 0) : NULL;
|
||||
|
||||
}
|
||||
|
||||
struct commit *lookup_commit(struct repository *r, const struct object_id *oid)
|
||||
{
|
||||
struct object *obj = lookup_object(r, oid);
|
||||
|
Reference in New Issue
Block a user