Follow

Keep Up to Date with the Most Important News

By pressing the Subscribe button, you confirm that you have read and are agreeing to our Privacy Policy and Terms of Use
Contact

.gitignore is hidden in VSCode

my VSCode (Insiders) hid the .gitignore a few days ago, and I cannot revert this, I tried searching a lot, but the solution of adding:

{
...
"files.exclude": {
    "**/.gitignore": false
  },
...
}

in settings.json doesn’t work, in the Settings with UI I only have:

  • .svn
  • .hg
  • CVS
  • .DS_Store
  • Thumbs.db

The .git folder isn’t hidden, nor .vscode or other files starting by ., just .gitignore.

MEDevel.com: Open-source for Healthcare and Education

Collecting and validating open-source software for healthcare, education, enterprise, development, medical imaging, medical records, and digital pathology.

Visit Medevel

I’m using VSCode Insiders 1.69.0-insider, commit 4c72dedb4ad283a569f83a7389468c3ae2c742c3.

>Solution :

This might be because vscode/issue 152891 has been fixed:

set "explorer.excludeGitIgnore": "true"

Meaning excludeGitIgnore is now working in insider.

This is discussed in issue 152543:

Looks like a recent change means .gitignore now always gets hidden in Explorer unless you have set "explorer.excludeGitIgnore": true, in which case the .gitignore file shows but none of the .gitignored files do.

I saw that even having a folder without Git initialized in it still results in the .gitignore being hidden.
Seems like it’s a default behavior and the explorer.excludeGitIgnore setting changes this behavior.

I tried messing with the Files: Exclude setting and adding a negated glob (or whatever that’s officially called) to get the gitignore back, but that didn’t work.

It should be fixed now.

Add a comment

Leave a Reply

Keep Up to Date with the Most Important News

By pressing the Subscribe button, you confirm that you have read and are agreeing to our Privacy Policy and Terms of Use

Discover more from Dev solutions

Subscribe now to keep reading and get access to the full archive.

Continue reading