Remove directory from remote repository after adding them to .gitignore

Remove directory from remote repository after adding them to .gitignore

git rm -r –cached some-directory
git commit -m ‘Remove the now ignored directory “some-directory”‘
git push origin master

 

Fonte: Remove directory from remote repository after adding them to .gitignore