deprecated-impl.js 768 B

123456789101112131415161718192021
  1. "use strict";
  2. Object.defineProperty(exports, "__esModule", { value: true });
  3. /**
  4. * @license
  5. * Copyright Google Inc. All Rights Reserved.
  6. *
  7. * Use of this source code is governed by an MIT-style license that can be
  8. * found in the LICENSE file at https://angular.io/license
  9. */
  10. const command_1 = require("../models/command");
  11. class DeprecatedCommand extends command_1.Command {
  12. async run() {
  13. let message = 'The "${this.description.name}" command has been deprecated.';
  14. if (this.description.name == 'get' || this.description.name == 'set') {
  15. message = 'get/set have been deprecated in favor of the config command.';
  16. }
  17. this.logger.error(message);
  18. return 0;
  19. }
  20. }
  21. exports.DeprecatedCommand = DeprecatedCommand;