GSI - Employe Self Service Mobile
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

20 lines
792 B

2 months ago
  1. "use strict";
  2. Object.defineProperty(exports, "__esModule", { value: true });
  3. exports.command = void 0;
  4. const clc = require("colorette");
  5. const command_1 = require("../command");
  6. const requireConfig_1 = require("../requireConfig");
  7. const utils = require("../utils");
  8. exports.command = new command_1.Command("target:clear <type> <target>")
  9. .description("clear all resources from a named resource target")
  10. .before(requireConfig_1.requireConfig)
  11. .action((type, name, options) => {
  12. const existed = options.rc.clearTarget(options.project, type, name);
  13. if (existed) {
  14. utils.logSuccess(`Cleared ${type} target ${clc.bold(name)}`);
  15. }
  16. else {
  17. utils.logWarning(`No action taken. No ${type} target found named ${clc.bold(name)}`);
  18. }
  19. return existed;
  20. });