简体   繁体   中英

Why is my git terminal stuck on a master branch?

Am hoping to get some answers to my git problem here. My terminal for whatever reason is stuck on this master branch that I didn't even initiate. Why is that? I've uninstalled and reinstalled git several times, but it's still showing the same. enter image description here

Whenever you initialize a git repo, you drop a hidden.git file inside the directory you put it in. It's possible your dropped a repo in a folder from a while ago and still have an existing.git file. You could run an ls -lisah or dir /a:h (or just.g tab complete) in order to check and then you can delete the.git file.

Uninstalling Git won't delete all your repos, and it looks like you did git init in your home directory, so Git's all set up to track absolutely everything. rm -rf.git to remove the repo.

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.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM