sfdx-ftw
Version:
sfdx For(ce) The Win!
28 lines • 910 B
JavaScript
;
Object.defineProperty(exports, "__esModule", { value: true });
const BaseConfig_1 = require("../../../util/BaseConfig");
class ConfigGet extends BaseConfig_1.BaseConfig {
async run() {
// if more than one varArgs passed, only return the first
const theKey = this.args.configKey;
const theVal = await this.getCheckConfig(theKey);
return JSON.parse(JSON.stringify({ key: theKey, value: theVal }));
}
}
exports.default = ConfigGet;
// accept one argument - the configured key
ConfigGet.args = [{ name: 'configKey' }];
// configure output result
ConfigGet.result = {
tableColumnData: {
columns: [
{ key: 'key', label: 'Key' },
{ key: 'value', label: 'Value' }
]
},
display() {
const theData = this.data;
this.ux.table([theData], this.tableColumnData);
}
};
//# sourceMappingURL=get.js.map