netlify-cli 8.9.6 → 8.9.7

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,12 +1,12 @@
1
1
  {
2
2
  "name": "netlify-cli",
3
- "version": "8.9.6",
3
+ "version": "8.9.7",
4
4
  "lockfileVersion": 2,
5
5
  "requires": true,
6
6
  "packages": {
7
7
  "": {
8
8
  "name": "netlify-cli",
9
- "version": "8.9.6",
9
+ "version": "8.9.7",
10
10
  "hasInstallScript": true,
11
11
  "license": "MIT",
12
12
  "dependencies": {
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "netlify-cli",
3
3
  "description": "Netlify command line tool",
4
- "version": "8.9.6",
4
+ "version": "8.9.7",
5
5
  "author": "Netlify Inc.",
6
6
  "contributors": [
7
7
  "Mathias Biilmann <matt@netlify.com> (https://twitter.com/biilmann)",
@@ -470,7 +470,11 @@ class BaseCommand extends Command {
470
470
  return await resolveConfig({
471
471
  config: options.config,
472
472
  cwd,
473
- context: options.context || this.name(),
473
+ context:
474
+ options.context ||
475
+ process.env.CONTEXT ||
476
+ // Dev commands have a default context of `dev`, otherwise we let netlify/config handle default behavior
477
+ (['dev', 'dev:exec', 'dev:trace'].includes(this.name()) ? 'dev' : undefined),
474
478
  debug: this.opts().debug,
475
479
  siteId: options.siteId || (typeof options.site === 'string' && options.site) || state.get('siteId'),
476
480
  token,