summaryrefslogtreecommitdiff
path: root/include/git2/rebase.h
Commit message (Collapse)AuthorAgeFilesLines
* Merge pull request #4913 from implausible/feature/signing-rebase-commitsPatrick Steinhardt2019-08-091-1/+17
|\ | | | | Add sign capability to git_rebase_commit
| * fixup: code cleanup around rebase commit signingTyler Ang-Wanek2019-07-021-1/+1
| | | | | | | | | | Use ci_git_fail_with where appropriate. Use correct initializer for callback.
| * Include "commit.h" in "rebase.h" for git_commit_signing_cbTyler Ang-Wanek2019-06-251-0/+1
| |
| * fixup: More generic signing_cb for future flexibilityTyler Wanek2019-01-241-16/+1
| | | | | | | | | | In the case that we want to build merge + commit, cherrypick + commit, or even just build a commit with signing callback, `git_rebase_commit_signature_cb` particular callback should be made more generic. We also renamed `signature_cb` to `signing_cb` to improve clarity on the purpose of the callback (build a difference between a git_signature and the act of signing). So we've ended up with `git_commit_signing_cb`.
| * Single callback for commit signing in rebase w/ git_bufTyler Wanek2019-01-231-26/+4
| | | | | | Reduces the number of callbacks for signing a commit during a rebase operation to just one callback. That callback has 2 out git_buf parameters for signature and signature field. We use git_buf here, because we cannot make any assumptions about the heap allocator a user of the library might be using.
| * Add signing callbacks for git_rebase_commit in git_rebase_optionsTyler Wanek2019-01-231-1/+53
| | | | | | | | 2 callbacks have been added to git_rebase_options, git_rebase_commit_signature_cb and git_rebase_commit_signature_field_cb. When git_rebase_commit_signature_cb is present in git_rebase_options, it will be called whenever git_rebase_commit is performed, giving an opportunity to sign the commit. The signing procedure can be skipped if the callback specifies passthrough as the error. The git_rebase_commit_signature_field_cb will only be called if the other callback is present or did not passthrough, and it provides means to specify which field a signature is for. Git_rebase_options was chosen as the home for these callbacks as it keeps backwards compatibility with the current rebase api.
* | Rename opt init functions to `options_init`Edward Thomson2019-06-141-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | In libgit2 nomenclature, when we need to verb a direct object, we name a function `git_directobject_verb`. Thus, if we need to init an options structure named `git_foo_options`, then the name of the function that does that should be `git_foo_options_init`. The previous names of `git_foo_init_options` is close - it _sounds_ as if it's initializing the options of a `foo`, but in fact `git_foo_options` is its own noun that should be respected. Deprecate the old names; they'll now call directly to the new ones.
* | rebase: orig_head and onto accessorsErik Aigner2019-04-211-0/+28
|/ | | | | | | | 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.
* docs: standardize comment block for git_*_init_options functionsEtienne Samson2018-05-071-4/+5
|
* docs: fix more missing includesEtienne Samson2018-05-071-0/+2
|
* Fix a few checkout -> rebase typoscmn/typoCarlos Martín Nieto2016-02-221-1/+1
|
* rebase: persist a single in-memory indexEdward Thomson2016-02-151-6/+15
| | | | | | When performing an in-memory rebase, keep a single index for the duration, so that callers have the expected index lifecycle and do not hold on to an index that is free'd out from under them.
* rebase: allow custom merge_optionsEdward Thomson2016-02-111-1/+7
| | | | | | Allow callers of rebase to specify custom merge options. This may allow custom conflict resolution, or failing fast when conflicts are detected.
* rebase: introduce inmemory rebasingEdward Thomson2016-02-111-1/+16
| | | | | | | | | | Introduce the ability to rebase in-memory or in a bare repository. When `rebase_options.inmemory` is specified, the resultant `git_rebase` session will not be persisted to disk. Callers may still analyze the rebase operations, resolve any conflicts against the in-memory index and create the commits. Neither `HEAD` nor the working directory will be updated during this process.
* Fix a typo in documentationNicolas Vanheuverzwijn2016-02-031-1/+1
|
* rebase: correct documentation, CHANGELOGEdward Thomson2015-04-201-8/+8
|
* rebase: include checkout opts within rebase optsEdward Thomson2015-04-201-2/+3
|
* rebase: init and open take a rebase_optionsEdward Thomson2015-04-201-24/+30
| | | | | | `git_rebase_init` and `git_rebase_open` should take a `git_rebase_options` and use it for future rebase operations on that `rebase` object.
* rebase: take `checkout_options` where appropriateEdward Thomson2015-04-201-2/+9
|
* rebase: identify a rebase that has not startedEdward Thomson2015-04-201-0/+6
| | | | | | In `git_rebase_operation_current()`, indicate when a rebase has not started (with `GIT_REBASE_NO_OPERATION`) rather than conflating that with the first operation being in-progress.
* Remove the signature from ref-modifying functionsCarlos Martín Nieto2015-03-031-6/+1
| | | | | | | | | | The signature for the reflog is not something which changes dynamically. Almost all uses will be NULL, since we want for the repository's default identity to be used, making it noise. In order to allow for changing the identity, we instead provide git_repository_set_ident() and git_repository_ident() which allow a user to override the choice of signature.
* rebase: allow `NULL` branch to indicate `HEAD`Edward Thomson2015-02-131-1/+2
| | | | | Don't require the branch to rebase, if given `NULL`, simply look up `HEAD`.
* Fix doc comment formattingBen Chatelain2015-02-101-5/+5
|
* doc: add documentation to all the public structs and enumscmn/doc-allCarlos Martín Nieto2014-12-061-1/+14
| | | | | | | | | | This makes them show up in the reference, even if the text itself isn't the most descriptive. These have been found with grep -Przon '\n\ntypedef struct.*?\{' -- include grep -Przon '\n\ntypedef enum.*?\{' -- include
* rebase: updates based on PR commentsEdward Thomson2014-10-261-17/+15
|
* s/git_merge_head/git_annotated_commitEdward Thomson2014-10-261-3/+4
| | | | | Rename git_merge_head to git_annotated_commit, as it becomes used in more operations than just merge.
* rebase: oid member of operation should be constEdward Thomson2014-10-261-1/+1
|
* git_rebase: iterators for operationsEdward Thomson2014-10-261-0/+27
|
* rebase: preload all operationsEdward Thomson2014-10-261-2/+2
|
* rebase: init/open a git_rebase objectEdward Thomson2014-10-261-11/+32
|
* git_rebase_next: provide info about the operationEdward Thomson2014-10-261-6/+68
|
* git_rebase_finish: rewrite notes when finishing rebaseEdward Thomson2014-10-261-1/+12
|
* Introduce git_rebase_finish to complete a rebaseEdward Thomson2014-10-261-0/+12
|
* git_rebase_commit: drop already-picked commitsEdward Thomson2014-10-261-1/+3
| | | | | | Already cherry-picked commits should not be re-included. If all changes included in a commit exist in the upstream, then we should error with GIT_EAPPLIED.
* Introduce git_rebase_commitEdward Thomson2014-10-261-0/+28
| | | | Commit the current patch of a rebase process.
* Introduce git_rebase_nextEdward Thomson2014-10-261-0/+13
| | | | | | `git_rebase_next` will apply the next patch (or cherry-pick) operation, leaving the results checked out in the index / working directory so that consumers can resolve any conflicts, as appropriate.
* Introduce git_rebase_abortEdward Thomson2014-10-261-0/+13
| | | | | Abort an in-progress rebase and move the working directory and repository back to the ORIG_HEAD state.
* Introduce git_rebase to set up a rebase sessionEdward Thomson2014-10-261-0/+73
Introduce `git_rebase` to set up a rebase session that can then be continued. Immediately, only merge-type rebase is supported.