To delete a remote directory that is no longer wanted, use the command found here
git rm -r --cached some-directory
git commit -m 'Remove the now ignored directory "some-directory"'
git push origin master
To delete a branch, use the command found here
git push origin --delete <branchName>Sometimes git push takes a long time to finish, and a git status shows that: Your branch is Ahead by X commits. In this case, the local commits may contain something wrong. To revert to the current commit in the remote repository, use the command here
git reset --hard origin/master
No comments:
Post a Comment