Visual Studio Code: .git folder/file hidden
By default Visual Studio Code excludes files in a folder using the following settings:
"files.exclude": { "**/.git": true, "**/.svn": true, "**/.hg": true, "**/.DS_Store": true}
You can change your user settings or workspace settings to show the .git folder by adding these lines:
"files.exclude": { "**/.git": false}
The below steps can be followed to override the existing user setting:
- Menu Code → Preference → Setting
- Search for
files.exclude
- Mouse over
files.exclude
property, click on the edit icon and then opt for the copy to settings. - The above steps will add all the properties, but keep only those which need to be overridden. For this case: it should be, "files.exclude": { "**/.git": false }
- Close the user setting. the
.git
folder will automatically appear in the respective repository.
The settings for Visual Studio Code can be found:
- On a Windows or Linux computer, click menu File → Preferences → Settings
- On a Mac, click menu Code → Preferences → Settings
There are both users settings (for everyone) and workspace settings for individual projects.
More instructions can be found at:User and Workspace Settings