pub struct SourceRepo { /* private fields */ }Implementations§
Source§impl SourceRepo
impl SourceRepo
pub fn discover(start: &Path) -> OutpostResult<Self>
pub fn discover_with( start: &Path, env: &BTreeMap<OsString, OsString>, ) -> OutpostResult<Self>
pub fn at(path: impl Into<PathBuf>) -> OutpostResult<Self>
pub fn at_with( path: impl Into<PathBuf>, env: &BTreeMap<OsString, OsString>, ) -> OutpostResult<Self>
pub fn work_tree(&self) -> &Path
pub fn git_dir(&self) -> &Path
pub fn git_common_dir(&self) -> &Path
pub fn outpost_at(&self, path: &Path) -> OutpostResult<Outpost>
pub fn env(&self) -> &BTreeMap<OsString, OsString>
pub fn current_branch(&self) -> OutpostResult<BranchName>
pub fn checked_out_branches(&self) -> OutpostResult<Vec<BranchName>>
pub fn checked_out_worktree_for( &self, branch: &BranchName, ) -> OutpostResult<Option<PathBuf>>
pub fn is_dirty(&self) -> OutpostResult<bool>
pub fn upstream_for( &self, branch: &BranchName, ) -> OutpostResult<Option<UpstreamRef>>
pub fn remote_url(&self, remote: &RemoteName) -> OutpostResult<String>
pub fn branch_exists(&self, branch: &BranchName) -> OutpostResult<bool>
pub fn branch_oid(&self, branch: &BranchName) -> OutpostResult<Option<String>>
pub fn origin_branch_oid( &self, branch: &BranchName, ) -> OutpostResult<Option<String>>
pub fn remote_branch_oid( &self, remote: &RemoteName, branch: &BranchName, ) -> OutpostResult<Option<String>>
pub fn origin_default_branch(&self) -> OutpostResult<Option<BranchName>>
pub fn remote_default_branch( &self, remote: &RemoteName, ) -> OutpostResult<Option<BranchName>>
pub fn fetch_origin_default_branch( &self, ) -> OutpostResult<Option<(BranchName, String)>>
pub fn fetch_remote_default_branch( &self, remote: &RemoteName, ) -> OutpostResult<Option<(BranchName, String)>>
pub fn is_ancestor_oid( &self, ancestor: &str, descendant: &str, ) -> OutpostResult<bool>
pub fn is_branch_checked_out(&self, branch: &BranchName) -> OutpostResult<bool>
pub fn delete_branch_if_oid( &self, branch: &BranchName, expected_oid: &str, ) -> OutpostResult<()>
pub fn delete_origin_branch_if_oid( &self, branch: &BranchName, expected_oid: &str, ) -> OutpostResult<()>
pub fn delete_remote_branch_if_oid( &self, remote: &RemoteName, branch: &BranchName, expected_oid: &str, ) -> OutpostResult<()>
pub fn fast_forward_branch_from_origin( &self, branch: &BranchName, ) -> OutpostResult<()>
pub fn registry_path(&self) -> PathBuf
pub fn registry(&self) -> OutpostResult<Registry>
pub fn registry_mut(&self) -> OutpostResult<RegistryMut<'_>>
Auto Trait Implementations§
impl Freeze for SourceRepo
impl RefUnwindSafe for SourceRepo
impl Send for SourceRepo
impl Sync for SourceRepo
impl Unpin for SourceRepo
impl UnsafeUnpin for SourceRepo
impl UnwindSafe for SourceRepo
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