diff --git a/PULL_REQUEST_TEMPLATE.md b/PULL_REQUEST_TEMPLATE.md index 33c96359..64279be6 100644 --- a/PULL_REQUEST_TEMPLATE.md +++ b/PULL_REQUEST_TEMPLATE.md @@ -4,7 +4,7 @@ We appreciate the effort for this pull request but before that please make sure Please format the PR title appropriately based on the type of change: [!]: Where is one of: docs, chore, feat, fix, test. -Add a '!' after the type for breaking changes (e.g. feat!: new breaking feature). +Add a '!' after the type for breaking changes (e.g. feat!: new breaking feature) & add text "BREAKING CHANGE:" in commit msg. **All third-party contributors acknowledge that any contributions they provide will be made under the same open-source license that the open-source project is provided under.** diff --git a/package.json b/package.json index 9223008a..077c760c 100644 --- a/package.json +++ b/package.json @@ -29,9 +29,6 @@ "dependencies": { "@actions/core": "^1.0.0", "@actions/github": "^5.0.3", - "@oclif/command": "^1.8.15", - "@oclif/config": "^1.18.2", - "@oclif/errors": "^1.3.5", "@oclif/plugin-help": "^3.2.2", "@oclif/plugin-plugins": "^1.8.3", "@octokit/rest": "^19.0.3", @@ -44,7 +41,8 @@ "qs": "^6.9.4", "semver": "^7.3.2", "tsv": "^0.2.0", - "twilio": "^3.80.0" + "twilio": "^3.80.0", + "@oclif/core": "^1.13.1" }, "devDependencies": { "@oclif/test": "^1.2.6", diff --git a/src/base-commands/base-command.js b/src/base-commands/base-command.js index 543f7681..ea789206 100644 --- a/src/base-commands/base-command.js +++ b/src/base-commands/base-command.js @@ -1,5 +1,5 @@ -const { Command, flags: oclifFlags } = require('@oclif/command'); -const { CLIError } = require('@oclif/errors'); +const { Command, Flags: oclifFlags } = require('@oclif/core'); +const { Errors } = require('@oclif/core'); const pkg = require('../../package.json'); const MessageTemplates = require('../services/messaging/templates'); @@ -30,7 +30,7 @@ class BaseCommand extends Command { } async run() { - const { args, flags } = this.parse(this.constructor); + const { args, flags } = await this.parse(this.constructor); this.args = args; this.flags = flags; await this.loadConfig(); @@ -59,7 +59,7 @@ class BaseCommand extends Command { } async catch(error) { - if (!this.logger || instanceOf(error, CLIError)) { + if (!this.logger || instanceOf(error, Errors.CLIError)) { return super.catch(error); } diff --git a/src/base-commands/twilio-client-command.js b/src/base-commands/twilio-client-command.js index 24d7f1c2..4e9928e8 100644 --- a/src/base-commands/twilio-client-command.js +++ b/src/base-commands/twilio-client-command.js @@ -1,4 +1,4 @@ -const { flags } = require('@oclif/command'); +const { Flags: flags } = require('@oclif/core'); const BaseCommand = require('./base-command'); const CliRequestClient = require('../services/cli-http-client');