[−][src]Struct mhgit::commands::PullOptions
git pull
command.
use mhgit::{CommandOptions, Repository}; use mhgit::commands::PullOptions; let repo = Repository::new(); PullOptions::new() .remote("origin") .refspec("master") .run(&repo)?;
Implementations
impl PullOptions
[src]
pub fn new() -> PullOptions
[src]
Create a new set of git pull
options.
pub fn allow_unrelated(&mut self, val: bool) -> &mut PullOptions
[src]
Add --allow-unrelated option.
pub fn refspec(&mut self, file: impl ToString) -> &mut PullOptions
[src]
Add refspec to pull command.
pub fn refspecs<I, S>(&mut self, files: I) -> &mut PullOptions where
I: IntoIterator<Item = S>,
S: ToString,
[src]
I: IntoIterator<Item = S>,
S: ToString,
Add multiple refspecs to pull command.
pub fn remote(&mut self, repo: impl ToString) -> &mut PullOptions
[src]
Set remote repository source.
Trait Implementations
impl CommandOptions for PullOptions
[src]
type Output = ()
fn git_args(&self) -> Vec<&str>
[src]
fn parse_output(&self, out: &str) -> Result<Self::Output, Error>
[src]
fn run(&self, repo: &Repository) -> Result<Self::Output, Error>
[src]
impl Debug for PullOptions
[src]
impl Default for PullOptions
[src]
fn default() -> PullOptions
[src]
Auto Trait Implementations
impl RefUnwindSafe for PullOptions
impl Send for PullOptions
impl Sync for PullOptions
impl Unpin for PullOptions
impl UnwindSafe for PullOptions
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,