mirror of
https://github.com/rust-lang/rust-analyzer.git
synced 2025-08-22 11:24:24 +00:00
Merge #8951
8951: internal: migrate to vscode.FileSystem API r=matklad a=wxb1ank I encountered an error where `bootstrap()` attempts to create a directory with the path `C:\C:\...`. I couldn't find this reported anywhere else. Using the `vscode.FileSystem` API instead of the `fs` one works here. I assume the latter automatically prepends `C:\` to paths whereas the former does not. I don't know if this suggests `vscode.FileSystem` should be used in more places for consistency. Co-authored-by: wxb1ank <wxblank@gmail.com>
This commit is contained in:
commit
388a91c8a8
4 changed files with 38 additions and 47 deletions
|
@ -31,10 +31,10 @@ export class Config {
|
|||
enableProposedApi: boolean | undefined;
|
||||
} = vscode.extensions.getExtension(this.extensionId)!.packageJSON;
|
||||
|
||||
readonly globalStoragePath: string;
|
||||
readonly globalStorageUri: vscode.Uri;
|
||||
|
||||
constructor(ctx: vscode.ExtensionContext) {
|
||||
this.globalStoragePath = ctx.globalStorageUri.fsPath;
|
||||
this.globalStorageUri = ctx.globalStorageUri;
|
||||
vscode.workspace.onDidChangeConfiguration(this.onDidChangeConfiguration, this, ctx.subscriptions);
|
||||
this.refreshLogging();
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue