I did
git init
git add .
git commit -m "first commit"
git remote add origin https://githubrepo
git push
Everything worked, the code's up on GitHub. Now, can I delete the local repo without affecting the remote GitHub repo?
CodePudding user response:
Yes. Your local changes aren't bound to the remote changes in any way like OneDrive or Google Drive. With Git you need to explicitly sync between the remote and your local repo.
If you delete your local repository your operating system won't suddenly start issuing commands to sync your local changes to the remote.