I am new to git and now the following error occurs:
fatal: Reference has invalid format: 'refs/heads/SomeBranch' (Conflict through use of capital and small initial letters) Unexpected end of command stream
SomeBranch (capitalized!) was actually deleted earlier (local and on remote) and I am working on a local branch someBranch (not capitalized!). Then, I git add
my local changes and git commit -m "Some changes" -a
. The error occured while git push
and also when git push -u origin someBranch
. someBranch is not yet in the repo.
备份整个项目(以防万一),然后执行
awk '!/Conflict/' .git/packed-refs > tmp && mv tmp .git/packed-refs
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.