git remove committed directory code example Example: remove folders from remote git git rm -r --cached myFolder