diff --git a/CHANGELOG.md b/CHANGELOG.md index 859868c..b6a8087 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,6 +1,6 @@ # Change Log (vs-deploy) -## 9.24.1 (June 11th, 2017; sync when open) +## 9.24.2 (June 11th, 2017; sync when open) * displaying message in output channel when synching a file when opening it now * bugfixes diff --git a/package.json b/package.json index 83ac88c..0748e23 100644 --- a/package.json +++ b/package.json @@ -2,7 +2,7 @@ "name": "vs-deploy", "displayName": "Deploy", "description": "Commands for deploying files of your workspace to a destination.", - "version": "9.24.1", + "version": "9.24.2", "publisher": "mkloubert", "engines": { "vscode": "^1.6.0" diff --git a/src/helpers.ts b/src/helpers.ts index f91f5d8..90e399c 100644 --- a/src/helpers.ts +++ b/src/helpers.ts @@ -2424,8 +2424,8 @@ export function toRelativePath(path: string, baseDir?: string): string | false { try { let normalizedPath = replaceAllStrings(path, Path.sep, '/'); - let wsRootPath = replaceAllStrings(vscode.workspace.rootPath, Path.sep, '/'); - if (wsRootPath) { + let wsRootPath = replaceAllStrings(baseDir, Path.sep, '/'); + if ('' !== wsRootPath) { if (FS.existsSync(wsRootPath)) { if (FS.lstatSync(wsRootPath).isDirectory()) { if (0 === normalizedPath.indexOf(wsRootPath)) {