0

Visual Studio has a new intellisence database file and when I ran git status I found it

On branch master Your branch is up-to-date with 'origin/master'.
Untracked files:
(use "git add ..." to include in what will be committed)
ServerSideCode.VC.db

Like its predecessor, *.sdf, this can be added to .gitignore. I edited my .gitignore to include *.VC.db. Now when I run git status I see:

On branch master Your branch is up-to-date with 'origin/master'.
Untracked files:
(use "git add ..." to include in what will be committed)
ServerSideCode.VC.db

What additional step, beyond adding a file to the .gitignore file, do I need in order ro to remove the file from the list of untracked files returned by git status?

(N.B. I realise that I could run git status -uno but I want to know the additional step required to ignore new file types recently added to my .gitignore file.)

Community
  • 1
  • 1
dumbledad
  • 16,305
  • 23
  • 120
  • 273
  • You can try doing `git check-ignore -v ServerSideCode.VC.db`. If there is a gitignore rule properly configured, that should return which .gitignore file that contains a matching ignore rule. If that command returns nothing, then there is no ignore rule which matches the specified file. – Alderath Apr 06 '16 at 14:47

1 Answers1

2

After adding the extension to .gitignore it should no longer show up in git status. Are you sure there's no typo in your .gitignore, and that the file is placed correctly?

Emil Kantis
  • 1,069
  • 7
  • 17
  • Ah, I think I may have edited the wrong .gitignore. I edited the one in ~ but I think it may be the one in ~/Source/Repos/ServerSideCode I should have edited. I'll check, thanks. – dumbledad Apr 06 '16 at 13:40