0

I was doing the VSCode configuration, but accidentally I saw this command line which I am not sure what it is doing.

However, after running, it always creates the cache data whenever I start my VSCode.

Note: Whenever I typed this command in any directory, it'll automatically shown those folder and file in that directory.

enter image description here

1 Answers1

0

By setting --user-data-dir you're telling VS Code where it should keep your user / session data, which is why it's creating all of those new directories. This is necessary because when you run code as sudo, it doesn't know where your user data directory is, since you're running as a different user. Like this answer says, you probably shouldn't be running code with sudo: VSCode - what exactly --user-data-dir is specifiying. See that answer for suggestions on alternatives.

As for deleting the data it made, just a simple sudo rm -rf <dir> should do the trick (be careful of course).

Daniel Porteous
  • 5,536
  • 3
  • 25
  • 44