git remove tracked folder code example
Example 1: remove a folder from git tracking
git rm -r --cached path_to_your_folder/
Example 2: git remove directory from tracking
Remove the folder from your local git tracking, but keep it on your disk.
git rm -r --cached path_to_your_folder/
Example 3: git remove tracked files without deleting
git rm --cached -r mydirectory
Example 4: remove tracked files git
git rm --cached <file>