我對這個GitHub的倉庫中的單一分支(未掌握),現在我想重新命名它,由於某種原因,我得到這個錯誤:的Git拒絕刪除分支
git push origin :OldName
To [email protected]:user/gitRepo.git
! [remote rejected] OldName (refusing to delete the current branch: refs/heads/OldName)
error: failed to push some refs to '[email protected]:user/gitRepo.git'
這是因爲我沒有任何主分支?這裏是我的git branch -a
:
OldName
remotes/origin/HEAD -> origin/OldName
remotes/origin/OldName