Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Conversation

eaigner
Copy link

@eaigner eaigner commented Apr 21, 2019

The rebase struct stores fields with information about the current
rebase process, which were not accessible via a public interface.

Accessors for getting the orig_head and onto branch
names and object ids have been added.

The rebase struct stores fields with information about the current
rebase process, which were not accessible via a public interface.

Accessors for getting the `orig_head` and `onto` branch
names and object ids have been added.
@tiennou
Copy link
Contributor

tiennou commented Apr 23, 2019

Since you're poking around interactive rebase, this is my own poke around the rebase code. Started last year, quickly rebased, may contain hazardous material, YMMV.

Copy link
Contributor

@tiennou tiennou left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Apart from the accessor comment, this looks fine to me. Thanks @eaigner 👍 !

@eaigner
Copy link
Author

eaigner commented May 1, 2019

I reverted it to the original approach, since annotated commits seem overkill to me and I think its better to reflect the actual files on disk without having some voodoo magic inbetween. I left the string accessors with name instead of ref in their names, since its a name (char *) and not an actual git_reference object.

So the interface looks like this again:

const char *git_rebase_orig_head_name(git_rebase *rebase);
const git_oid *git_rebase_orig_head_id(git_rebase *rebase);
const char *git_rebase_onto_name(git_rebase *rebase);
const git_oid *git_rebase_onto_id(git_rebase *rebase);

@ethomson
Copy link
Member

LGTM. Thanks @eaigner!

@ethomson ethomson merged commit 7f562f2 into libgit2:master May 12, 2019
@eaigner
Copy link
Author

eaigner commented May 12, 2019

🎉😊

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants