git rm rf code example Example 1: git rm cached $ git rm --cached filename Example 2: how to remove stuff from git git rm -r File-Name