add typings installer user agent for npm requests (#12446)

* add typings installer user agent for npm requests

* address PR feedback: change name of user agent
This commit is contained in:
Vladimir Matveev
2016-11-22 14:56:18 -08:00
committed by GitHub
parent a8ef77c33c
commit 680fb2ea1b

View File

@@ -127,7 +127,7 @@ namespace ts.server.typingsInstaller {
if (this.log.isEnabled()) {
this.log.writeLine(`#${requestId} with arguments'${JSON.stringify(args)}'.`);
}
const command = `${this.npmPath} install ${args.join(" ")} --save-dev`;
const command = `${this.npmPath} install ${args.join(" ")} --save-dev --user-agent="typesInstaller/${version}"`;
const start = Date.now();
let stdout: Buffer;
let stderr: Buffer;