Struct git2::RebaseOptions

source ·
pub struct RebaseOptions<'cb> { /* private fields */ }
Expand description

Rebase options

Use to tell the rebase machinery how to operate.

Implementations§

source§

impl<'cb> RebaseOptions<'cb>

source

pub fn new() -> RebaseOptions<'cb>

Creates a new default set of rebase options.

source

pub fn quiet(&mut self, quiet: bool) -> &mut RebaseOptions<'cb>

Used by Repository::rebase, this will instruct other clients working on this rebase that you want a quiet rebase experience, which they may choose to provide in an application-specific manner. This has no effect upon libgit2 directly, but is provided for interoperability between Git tools.

source

pub fn inmemory(&mut self, inmemory: bool) -> &mut RebaseOptions<'cb>

Used by Repository::rebase, this will begin an in-memory rebase, which will allow callers to step through the rebase operations and commit the rebased changes, but will not rewind HEAD or update the repository to be in a rebasing state. This will not interfere with the working directory (if there is one).

source

pub fn rewrite_notes_ref( &mut self, rewrite_notes_ref: &str ) -> &mut RebaseOptions<'cb>

Used by finish(), this is the name of the notes reference used to rewrite notes for rebased commits when finishing the rebase; if NULL, the contents of the configuration option notes.rewriteRef is examined, unless the configuration option notes.rewrite.rebase is set to false. If notes.rewriteRef is also NULL, notes will not be rewritten.

source

pub fn merge_options(&mut self, opts: MergeOptions) -> &mut RebaseOptions<'cb>

Options to control how trees are merged during next().

source

pub fn checkout_options( &mut self, opts: CheckoutBuilder<'cb> ) -> &mut RebaseOptions<'cb>

Options to control how files are written during Repository::rebase, next() and abort(). Note that a minimum strategy of GIT_CHECKOUT_SAFE is defaulted in init and next, and a minimum strategy of GIT_CHECKOUT_FORCE is defaulted in abort to match git semantics.

source

pub fn raw(&mut self) -> *const git_rebase_options

Acquire a pointer to the underlying raw options.

Trait Implementations§

source§

impl<'cb> Default for RebaseOptions<'cb>

source§

fn default() -> Self

Returns the “default value” for a type. Read more

Auto Trait Implementations§

§

impl<'cb> Freeze for RebaseOptions<'cb>

§

impl<'cb> !RefUnwindSafe for RebaseOptions<'cb>

§

impl<'cb> !Send for RebaseOptions<'cb>

§

impl<'cb> !Sync for RebaseOptions<'cb>

§

impl<'cb> Unpin for RebaseOptions<'cb>

§

impl<'cb> !UnwindSafe for RebaseOptions<'cb>

Blanket Implementations§

source§

impl<T> Any for T
where T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

impl<T> Borrow<T> for T
where T: ?Sized,

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
source§

impl<T> From<T> for T

source§

fn from(t: T) -> T

Returns the argument unchanged.

source§

impl<T, U> Into<U> for T
where U: From<T>,

source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

§

type Error = Infallible

The type returned in the event of a conversion error.
source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.