I am trying Visual Studio Code at this moment. Everything about Visual Studio Code look really cool to me except one thing: .git folder/file is hidden in Visual Studio Code.
I often change Git setting by modifying the .git
configuration file. It is really annoying for me not able to see .git
files.
Is there a way to reveal .git
files in Visual Studio Code?
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
}
This setting can also be found in Text Editor
-> Files
-> Exclude
if you are using the settings GUI.
To open the settings JSON for editing, do the following:
Open the command pallete:
Windows: ctrl+shift+p
or
Mac: ⌘ + Shift + P
In the command prompt that should open, type Preferences: Open Workspace Settings (JSON)
.
This should open the settings JSON file for you.
Note: You will notice similar commands appear if you prefer to choose settings more specific to your user or workspace.
Find files.exclude
and you should see the relevant section to edit.