@microsoft/api-extractor
Version:
Validate, document, and review the exported API for a TypeScript library
35 lines (33 loc) • 1.18 kB
JavaScript
;
// Copyright (c) Microsoft Corporation. All rights reserved. Licensed under the MIT license.
// See LICENSE in the project root for license information.
Object.defineProperty(exports, "__esModule", { value: true });
const os = require("os");
const colors = require("colors");
const ts_command_line_1 = require("@microsoft/ts-command-line");
const RunAction_1 = require("./RunAction");
class ApiExtractorCommandLine extends ts_command_line_1.CommandLineParser {
constructor() {
super({
toolFilename: 'api-extractor',
toolDescription: 'This is an experimental command line interface for the API Extractor tool.'
});
this._populateActions();
}
onDefineParameters() {
}
onExecute() {
try {
super.onExecute();
}
catch (error) {
console.error(os.EOL + colors.red('ERROR: ' + error.message.trim()));
process.exitCode = 1;
}
}
_populateActions() {
this.addAction(new RunAction_1.RunAction(this));
}
}
exports.ApiExtractorCommandLine = ApiExtractorCommandLine;
//# sourceMappingURL=ApiExtractorCommandLine.js.map