use path.normalize for extpath.normalize(.., true)

This commit is contained in:
Martin Aeschlimann
2019-02-15 15:03:30 +01:00
parent ad209fbf7b
commit 92a61b8d16
18 changed files with 46 additions and 51 deletions

View File

@@ -8,7 +8,7 @@ import { CancellationTokenSource } from 'vs/base/common/cancellation';
import * as errors from 'vs/base/common/errors';
import { Emitter, Event } from 'vs/base/common/event';
import { TernarySearchTree } from 'vs/base/common/map';
import * as extpath from 'vs/base/common/extpath';
import * as path from 'vs/base/common/path';
import * as platform from 'vs/base/common/platform';
import Severity from 'vs/base/common/severity';
import { URI } from 'vs/base/common/uri';
@@ -866,7 +866,7 @@ class Extension<T> implements vscode.Extension<T> {
this._extensionService = extensionService;
this._identifier = description.identifier;
this.id = description.identifier.value;
this.extensionPath = extpath.normalize(originalFSPath(description.extensionLocation), true);
this.extensionPath = path.normalize(originalFSPath(description.extensionLocation));
this.packageJSON = description;
}

View File

@@ -3,7 +3,7 @@
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
import * as extpath from 'vs/base/common/extpath';
import * as path from 'vs/base/common/path';
import { Schemas } from 'vs/base/common/network';
import { URI, UriComponents } from 'vs/base/common/uri';
import { Event, Emitter } from 'vs/base/common/event';
@@ -881,7 +881,7 @@ export class ExtHostVariableResolverService extends AbstractVariableResolverServ
if (activeEditor) {
const resource = activeEditor.document.uri;
if (resource.scheme === Schemas.file) {
return extpath.normalize(resource.fsPath, true);
return path.normalize(resource.fsPath);
}
}
return undefined;

View File

@@ -354,7 +354,7 @@ export class ExtHostWorkspaceProvider {
if (includeWorkspace) {
result = `${folder.name}/${result}`;
}
return normalize(result, true);
return normalize(result);
}
private trySetWorkspaceFolders(folders: vscode.WorkspaceFolder[]): void {