mirror of
https://github.com/microsoft/TypeScript.git
synced 2026-05-22 12:03:44 -05:00
adjust typing directory
This commit is contained in:
@@ -179,11 +179,11 @@ namespace ts.server {
|
||||
basePath = os.homedir();
|
||||
break;
|
||||
case "darwin":
|
||||
basePath = combinePaths(os.homedir(), "/Library/Application Support/")
|
||||
basePath = combinePaths(os.homedir(), "Library/Application Support/")
|
||||
break;
|
||||
}
|
||||
if (basePath) {
|
||||
this.cachePath = combinePaths(normalizeSlashes(basePath), "/Microsoft/TypeScript");
|
||||
this.cachePath = combinePaths(normalizeSlashes(basePath), "Microsoft/TypeScript");
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -60,7 +60,8 @@ namespace ts.server.typingsInstaller {
|
||||
this.runTsd(req.cachePath, typingsToInstall, installedTypings => {
|
||||
// TODO: record new missing package names
|
||||
// TODO: watch project directory
|
||||
installedTypings = installedTypings.map(x => getNormalizedAbsolutePath(x, req.cachePath));
|
||||
const typingDirectory = combinePaths(req.cachePath, "typings");
|
||||
installedTypings = installedTypings.map(x => combinePaths(typingDirectory, x));
|
||||
this.sendResponse(this.createResponse(req, currentlyCachedTypings.concat(installedTypings)));
|
||||
});
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user