UNPKG

git-commit-stamper

Version:

Updates a log file with selected last git commit data

36 lines 1.41 kB
#!/usr/bin/env node "use strict"; var __importDefault = (this && this.__importDefault) || function (mod) { return (mod && mod.__esModule) ? mod : { "default": mod }; }; Object.defineProperty(exports, "__esModule", { value: true }); const yargs_1 = __importDefault(require("yargs")); const handle_stamper_1 = require("../handle-stamper"); const handle_tags_1 = require("../handle-tags"); (async () => { return yargs_1.default .wrap(yargs_1.default.terminalWidth()) .command('parse <logFile> [outFile]', 'Parses a log file with template tags and replaces the tags with the last git commit info.', // @ts-ignore yargs => { yargs .positional('logFile', { type: 'string', describe: 'The log file to ingest.' }) .options({ outFile: { type: 'string', description: 'Writes output to specified file instead of the original.' }, simulate: { default: false, type: 'boolean', description: 'Prints log output, does not write any data.' } }); }, handle_stamper_1.handleStamper) .command('tags', 'Shows the template data that would be fed into handlebars.', () => { }, handle_tags_1.handleTags) .demandCommand(1, '').argv; })(); //# sourceMappingURL=git-commit-stamper.js.map