mirror of
https://github.com/microsoft/TypeScript.git
synced 2025-11-18 17:21:48 +00:00
Update LKG
This commit is contained in:
Vendored
+4
@@ -1543,6 +1543,10 @@ declare namespace ts.server.protocol {
|
||||
* Comma separated list of installed typing packages
|
||||
*/
|
||||
installedPackages: string;
|
||||
/**
|
||||
* true if install request succeeded, otherwise - false
|
||||
*/
|
||||
installSuccess: boolean;
|
||||
}
|
||||
interface NavBarResponse extends Response {
|
||||
body?: NavigationBarItem[];
|
||||
|
||||
+1
-1
@@ -37138,7 +37138,7 @@ var ts;
|
||||
})(ts || (ts = {}));
|
||||
var ts;
|
||||
(function (ts) {
|
||||
ts.version = "2.0.8";
|
||||
ts.version = "2.0.9";
|
||||
var emptyArray = [];
|
||||
function findConfigFile(searchPath, fileExists, configName) {
|
||||
if (configName === void 0) { configName = "tsconfig.json"; }
|
||||
|
||||
+3
-2
@@ -38553,7 +38553,7 @@ var ts;
|
||||
})(ts || (ts = {}));
|
||||
var ts;
|
||||
(function (ts) {
|
||||
ts.version = "2.0.8";
|
||||
ts.version = "2.0.9";
|
||||
var emptyArray = [];
|
||||
function findConfigFile(searchPath, fileExists, configName) {
|
||||
if (configName === void 0) { configName = "tsconfig.json"; }
|
||||
@@ -56346,7 +56346,8 @@ var ts;
|
||||
var body = {
|
||||
telemetryEventName: "typingsInstalled",
|
||||
payload: {
|
||||
installedPackages: response.packagesToInstall.join(",")
|
||||
installedPackages: response.packagesToInstall.join(","),
|
||||
installSuccess: response.installSuccess
|
||||
}
|
||||
};
|
||||
var eventName = "telemetry";
|
||||
|
||||
Vendored
+1
@@ -663,6 +663,7 @@ declare namespace ts.server.protocol {
|
||||
}
|
||||
interface TypingsInstalledTelemetryEventPayload {
|
||||
installedPackages: string;
|
||||
installSuccess: boolean;
|
||||
}
|
||||
interface NavBarResponse extends Response {
|
||||
body?: NavigationBarItem[];
|
||||
|
||||
@@ -38553,7 +38553,7 @@ var ts;
|
||||
})(ts || (ts = {}));
|
||||
var ts;
|
||||
(function (ts) {
|
||||
ts.version = "2.0.8";
|
||||
ts.version = "2.0.9";
|
||||
var emptyArray = [];
|
||||
function findConfigFile(searchPath, fileExists, configName) {
|
||||
if (configName === void 0) { configName = "tsconfig.json"; }
|
||||
|
||||
+1
-1
@@ -44687,7 +44687,7 @@ var ts;
|
||||
var ts;
|
||||
(function (ts) {
|
||||
/** The version of the TypeScript compiler release */
|
||||
ts.version = "2.0.8";
|
||||
ts.version = "2.0.9";
|
||||
var emptyArray = [];
|
||||
function findConfigFile(searchPath, fileExists, configName) {
|
||||
if (configName === void 0) { configName = "tsconfig.json"; }
|
||||
|
||||
@@ -44687,7 +44687,7 @@ var ts;
|
||||
var ts;
|
||||
(function (ts) {
|
||||
/** The version of the TypeScript compiler release */
|
||||
ts.version = "2.0.8";
|
||||
ts.version = "2.0.9";
|
||||
var emptyArray = [];
|
||||
function findConfigFile(searchPath, fileExists, configName) {
|
||||
if (configName === void 0) { configName = "tsconfig.json"; }
|
||||
|
||||
+16
-7
@@ -5878,7 +5878,7 @@ var ts;
|
||||
}
|
||||
this.knownCachesSet[cacheLocation] = true;
|
||||
};
|
||||
TypingsInstaller.prototype.filterAndMapToScopedName = function (typingsToInstall) {
|
||||
TypingsInstaller.prototype.filterTypings = function (typingsToInstall) {
|
||||
if (typingsToInstall.length === 0) {
|
||||
return typingsToInstall;
|
||||
}
|
||||
@@ -5891,7 +5891,7 @@ var ts;
|
||||
var validationResult = validatePackageName(typing);
|
||||
if (validationResult === PackageNameValidationResult.Ok) {
|
||||
if (typing in this.typesRegistry) {
|
||||
result.push("@types/" + typing);
|
||||
result.push(typing);
|
||||
}
|
||||
else {
|
||||
if (this.log.isEnabled()) {
|
||||
@@ -5942,7 +5942,8 @@ var ts;
|
||||
if (this.log.isEnabled()) {
|
||||
this.log.writeLine("Installing typings " + JSON.stringify(typingsToInstall));
|
||||
}
|
||||
var scopedTypings = this.filterAndMapToScopedName(typingsToInstall);
|
||||
var filteredTypings = this.filterTypings(typingsToInstall);
|
||||
var scopedTypings = filteredTypings.map(function (x) { return ("@types/" + x); });
|
||||
if (scopedTypings.length === 0) {
|
||||
if (this.log.isEnabled()) {
|
||||
this.log.writeLine("All typings are known to be missing or invalid - no need to go any further");
|
||||
@@ -5956,18 +5957,26 @@ var ts;
|
||||
if (_this.telemetryEnabled) {
|
||||
_this.sendResponse({
|
||||
kind: server.EventInstall,
|
||||
packagesToInstall: scopedTypings
|
||||
packagesToInstall: scopedTypings,
|
||||
installSuccess: ok
|
||||
});
|
||||
}
|
||||
if (!ok) {
|
||||
if (_this.log.isEnabled()) {
|
||||
_this.log.writeLine("install request failed, marking packages as missing to prevent repeated requests: " + JSON.stringify(filteredTypings));
|
||||
}
|
||||
for (var _i = 0, filteredTypings_1 = filteredTypings; _i < filteredTypings_1.length; _i++) {
|
||||
var typing = filteredTypings_1[_i];
|
||||
_this.missingTypingsSet[typing] = true;
|
||||
}
|
||||
return;
|
||||
}
|
||||
if (_this.log.isEnabled()) {
|
||||
_this.log.writeLine("Requested to install typings " + JSON.stringify(scopedTypings) + ", installed typings " + JSON.stringify(scopedTypings));
|
||||
}
|
||||
var installedTypingFiles = [];
|
||||
for (var _i = 0, scopedTypings_1 = scopedTypings; _i < scopedTypings_1.length; _i++) {
|
||||
var t = scopedTypings_1[_i];
|
||||
for (var _a = 0, scopedTypings_1 = scopedTypings; _a < scopedTypings_1.length; _a++) {
|
||||
var t = scopedTypings_1[_a];
|
||||
var packageName = ts.getBaseFileName(t);
|
||||
if (!packageName) {
|
||||
continue;
|
||||
@@ -6161,7 +6170,7 @@ var ts;
|
||||
if (_this.log.isEnabled()) {
|
||||
_this.log.writeLine("npm install #" + requestId + " took: " + (Date.now() - start) + " ms" + ts.sys.newLine + "stdout: " + stdout + ts.sys.newLine + "stderr: " + stderr);
|
||||
}
|
||||
onRequestCompleted(!!stdout);
|
||||
onRequestCompleted(!err);
|
||||
});
|
||||
};
|
||||
return NodeTypingsInstaller;
|
||||
|
||||
Reference in New Issue
Block a user