@bioneisme/greenfield-cli
Version:
CLI For BNB Greenfield SDK
36 lines (35 loc) • 1.79 kB
JavaScript
;
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
return new (P || (P = Promise))(function (resolve, reject) {
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
step((generator = generator.apply(thisArg, _arguments || [])).next());
});
};
Object.defineProperty(exports, "__esModule", { value: true });
const commander_1 = require("commander");
const getAllowence_1 = require("../commands/feegrant/getAllowence");
const grantAllowance_1 = require("../commands/feegrant/grantAllowance");
const getAllowences_1 = require("../commands/feegrant/getAllowences");
const feegrant = commander_1.program.command("feegrant").description("feegrant operations");
feegrant
.command("get-allowence <grantee>")
.description("get allowence")
.action((grantee) => __awaiter(void 0, void 0, void 0, function* () {
yield (0, getAllowence_1.getAllowence)(grantee);
}));
feegrant
.command("get-allowences <grantee>")
.description("get allowences")
.action((grantee) => __awaiter(void 0, void 0, void 0, function* () {
yield (0, getAllowences_1.getAllowences)(grantee);
}));
feegrant
.command("grant-allowence <grantee>")
.description("grant allowence")
.action((grantee) => __awaiter(void 0, void 0, void 0, function* () {
yield (0, grantAllowance_1.grantAllowance)(grantee);
}));
exports.default = feegrant;