pub fn rename_branch(old: &str, new: &str) -> Result<()>
Rename a branch and keep the stack intact. Git moves the branch’s own metadata with the rename; children pointing at the old name are retargeted here.