MCPcopy Create free account
hub / github.com/dashed/git-chain / get_current_branch_name

Function get_current_branch_name

tests/common/mod.rs:190–193  ·  view source on GitHub ↗
(repo: &Repository)

Source from the content-addressed store, hash-verified

188
189#[allow(dead_code)]
190pub fn get_current_branch_name(repo: &Repository) -> String {
191 let head = repo.head().unwrap();
192 head.shorthand().unwrap().to_string()
193}
194
195pub fn create_new_file(path_to_repo: &Path, file_name: &str, file_contents: &str) {
196 let mut file = OpenOptions::new()

Calls

no outgoing calls