git2-rs icon indicating copy to clipboard operation
git2-rs copied to clipboard

Support git_commit_create_cb in RebaseOptions

Open CouleeApps opened this issue 2 years ago • 3 comments

Currently, the RebaseOptions structure is missing support for commit_create_cb from the git_rebase_options C structure, which is used to facilitate things like commit signing in rebase operations. It would be useful to have safe access to this field to allow for custom commit signing abilities for rebase operations. It looks like the git_rebase_options structure has a payload field at the end which can be used for maintaining state across the FFI boundary, so implementation is hopefully not too complicated.

Followup discussion: signing_cb is also unimplemented, but marked as deprecated in the libgit2 C api. As such, it does not seem necessary to me to implement support for it. commit_create_cb seems to supersede its functionality.

CouleeApps avatar Jun 22 '22 00:06 CouleeApps

I need this feature for something I'm working on. Would love to add it if its something the maintainers are okay with.

Pranav2612000 avatar Mar 16 '24 06:03 Pranav2612000

@Pranav2612000 just open a PR 👍

extrawurst avatar Mar 16 '24 14:03 extrawurst

@extrawurst Just got around to looking at the issue. I've opened up a PR - https://github.com/rust-lang/git2-rs/pull/1047 Can you help with the review?

Pranav2612000 avatar Apr 28 '24 13:04 Pranav2612000