I have created a .gitignore file in the folder with the .git folder, but I still get the files I'm trying to ignore when doing a rescan of the repository.
This is the content of the file.
# Ignored files
*.suo
*.user
bin
obj
*.pdb
*.cache
*_svn
*.svn
*.suo
*.user
*.build-res
TestResults
_ReSharper*
What am I doing wrong? where is the file suppose to be located?
To ignore files in your repository with GitHub Desktop go to the Repository menu and select Repository Settings… With the Repository Settings pop-up open, click the Ignored Files tab. Here you will be able to add file names, directory names, or patterns for Git to ignore in your repository.
You need to make sure the file you are still seeing are not currently committed or staged. If you remove them ( git rm or git rm --cached ), and then add them as private file, then they will be ignored.
gitignore with contents /bin will make it ignore files or folders named bin in th esame folder as the . gitignore . If you want to specify that bin should be a folder, then put a trailing slash. To sum it up, using /bin/ will ignore only the bin folder in the same folder of the .
You need to make sure the file you are still seeing are not currently committed or staged.
If you remove them (git rm
or git rm --cached
), and then add them as private file, then they will be ignored.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With