Reputation: 67533
User is a directory that contains: snippets.json, keybindings.json, settings.json...
Mac
/Windows
/Linux
OS
System
/User
level installation
Stable
/Insiders
/Exploration
/OSS
installs all have different paths.
I want to get it just like vscode.env.appRoot
works. Is it possible?
Upvotes: 1
Views: 439
Reputation: 67533
This seems to be working:
const UserDirectoryPath = path.join(extensionContext.logPath, '../../../..', 'User');
Upvotes: 1
Reputation: 53317
In you activation function for your extension you'll get an ExtensionContext
instance, which has a property extensionPath
.
Upvotes: 0