pub trait GitCommand: Command {
// Provided methods
fn validate_git_repo(&self) -> Result<()> { ... }
fn repo_root(&self) -> Result<String> { ... }
fn current_branch(&self) -> Result<String> { ... }
}
Expand description
Trait for commands that work with git repositories
Provided Methods§
Sourcefn validate_git_repo(&self) -> Result<()>
fn validate_git_repo(&self) -> Result<()>
Validate that we’re in a git repository
Sourcefn current_branch(&self) -> Result<String>
fn current_branch(&self) -> Result<String>
Get the current branch