@cliz/gpm
Version:
Git Project Manager
24 lines (23 loc) • 807 B
JavaScript
;
Object.defineProperty(exports, "__esModule", { value: true });
const cli_1 = require("@cliz/cli");
const core_1 = require("../../core");
exports.default = (0, cli_1.defineSubCommand)((createCommand) => {
return createCommand('Get gpm config')
.argument('<key>', 'The Config Key')
.option('-g, --global', 'Get global config')
.action(async ({ args }) => {
var _a;
try {
const key = args.key;
// const global = options.global as any as boolean;
//
await core_1.default.prepare();
const value = (_a = core_1.default.config.get(key)) !== null && _a !== void 0 ? _a : '';
console.log(value);
}
catch (error) {
console.error(error);
}
});
});