UNPKG

1.28 kBJavaScriptView Raw
1"use strict";
2var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
3 return new (P || (P = Promise))(function (resolve, reject) {
4 function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
5 function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
6 function step(result) { result.done ? resolve(result.value) : new P(function (resolve) { resolve(result.value); }).then(fulfilled, rejected); }
7 step((generator = generator.apply(thisArg, _arguments || [])).next());
8 });
9};
10function __export(m) {
11 for (var p in m) if (!exports.hasOwnProperty(p)) exports[p] = m[p];
12}
13Object.defineProperty(exports, "__esModule", { value: true });
14__export(require("./types"));
15const commit_1 = require("./commit");
16function main(options) {
17 return __awaiter(this, void 0, void 0, function* () {
18 const repositoryPath = options.repositoryPath ? options.repositoryPath : process.argv[1];
19 const originalWorkingDirector = process.cwd();
20 let result;
21 process.chdir(repositoryPath);
22 result = yield commit_1.default(options);
23 return result;
24 });
25}
26exports.default = main;
27;
28//# sourceMappingURL=index.js.map
\No newline at end of file