1. git rm --cached (i.e. app/**/*.xml) 2. Commit the removal. 3. Add the pattern to your .gitignore to avoid it in the future.