pub struct LocalRepositoryBuilder {
pub base_dir: PathBuf,
pub head: String,
pub description: Option<String>,
}
Expand description
Helper struct for initializing a local repository
A repository on a local downstream is structured as:
Raw files are not supported for local downstream/
Fields§
§base_dir: PathBuf
Path to the root directory of all mirrors stored locally
head: String
Default branch of the repository
description: Option<String>
Description of the repository
Implementations§
Source§impl LocalRepositoryBuilder
impl LocalRepositoryBuilder
Sourcepub fn git_directory_is_initialized(&self, dir: &Path) -> bool
pub fn git_directory_is_initialized(&self, dir: &Path) -> bool
Conditionally skips initialization if the repository already exists on disk
Sourcepub fn description(self, description: Option<String>) -> Self
pub fn description(self, description: Option<String>) -> Self
Set the description of a local repository
Trait Implementations§
Source§impl Clone for LocalRepositoryBuilder
impl Clone for LocalRepositoryBuilder
Source§fn clone(&self) -> LocalRepositoryBuilder
fn clone(&self) -> LocalRepositoryBuilder
Returns a copy of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreAuto Trait Implementations§
impl Freeze for LocalRepositoryBuilder
impl RefUnwindSafe for LocalRepositoryBuilder
impl Send for LocalRepositoryBuilder
impl Sync for LocalRepositoryBuilder
impl Unpin for LocalRepositoryBuilder
impl UnwindSafe for LocalRepositoryBuilder
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more