简体   繁体   中英

How do I remove a git repository from my computer while keeping the online version?

I'm somewhat of a beginner with git, is there a good way to remove the local repository but keep my github backup? Thanks in advance!

  • Upload all the content to your remote
  • Delete the local folder.

# upload all tags, branches to your remote
git push origin --all

# delete the local folder
git rm -rf .

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