UNPKG

1.75 kBJavaScriptView Raw
1#!/usr/bin/env node
2"use strict";
3/*
4 * Copyright © 2018 Atomist, Inc.
5 *
6 * See LICENSE file.
7 */
8var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
9 function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
10 return new (P || (P = Promise))(function (resolve, reject) {
11 function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
12 function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
13 function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
14 step((generator = generator.apply(thisArg, _arguments || [])).next());
15 });
16};
17Object.defineProperty(exports, "__esModule", { value: true });
18// tslint:disable-next-line:no-import-side-effect
19require("source-map-support/register");
20const error_1 = require("../lib/util/error");
21/* tslint:disable:no-console */
22function main() {
23 return __awaiter(this, void 0, void 0, function* () {
24 try {
25 const logging = require("../lib/util/logger");
26 logging.configureLogging(logging.ClientLogging);
27 let configuration = yield require("../lib/configuration").loadConfiguration();
28 configuration = require("../lib/scan").enableDefaultScanning(configuration);
29 yield require("../lib/automationClient").automationClient(configuration).run();
30 }
31 catch (e) {
32 error_1.printError(e);
33 process.exit(5);
34 }
35 });
36}
37main()
38 .catch(e => {
39 console.error(`Unhandled exception: ${e.message}`);
40 process.exit(10);
41});
42//# sourceMappingURL=start.js.map
\No newline at end of file