- Create a file .gitignore in the root directory of your repository
- Add to the above file the path of file/directory you want to be excluded from your local git tracking.
- Type the following command: git rm -r --cached your_dir_path/
- Push your changes to your git repo
"The folder will be considered "deleted" from Git's point of view (i.e. they are in past history, but not in the latest commit, and people pulling from this repo will get the files removed from their trees), but stay on your working directory because you've used --cached."
References:
http://stackoverflow.com/questions/24290358/remove-a-folder-from-git-tracking
No comments:
Post a Comment