Dot and underscore showing with file name when open folder in VS code editor or Sublime editor

3.2k views Asked by At

I am using MacBook Air. I downloaded the visual code editor from here. I tested the page and it's working.

I am getting an issue with the file name. I am getting the file name twice. The first file name starts from the ._ and my second file name is correct.

For example.

I have the files below the files in my folder.

about.php index.php

When I open in visual studio code editor then I am getting

._about.php
._index.php
about.php
index.php

Please let me know what is the issue with my editor.

enter image description here

Would you help me out with this issue?

Now I am getting the same issue on the sublime editor.

3

There are 3 answers

1
hoogw On

If your file is on a hard drive with exFAT format, Mac will automatically generate dot underscore file. Dot underscore files are Mac system files and unrelated to visual studio code. They are the result of storing your files on a hard drive partition that does not support extended file attributes. They have likely always been there on your Mac, but since they are OS X system files, they were hidden

more details https://apple.stackexchange.com/questions/14980/why-are-dot-underscore-files-created-and-how-can-i-avoid-them

2
Santhosh On

find . -name "._*" -type f -delete

1
lisichka ggg On

For VSCode users you actually can hide these files from sidebar :

Go to Code > Preferences > Settings. Search for files:exclude in the search at the top. Add new pattern (any file which starts with ._):

**/._*

Here what it looks like on my machine

enter image description here