@oclif/core 2.9.2 → 2.9.4

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.
package/lib/help/index.js CHANGED
@@ -107,7 +107,11 @@ class Help extends HelpBase {
107
107
  if (this.config.flexibleTaxonomy) {
108
108
  const matches = this.config.findMatches(subject, originalArgv);
109
109
  if (matches.length > 0) {
110
- const result = await this.config.runHook('command_incomplete', { id: subject, argv: originalArgv, matches });
110
+ const result = await this.config.runHook('command_incomplete', {
111
+ id: subject,
112
+ argv: originalArgv.filter(o => !subject.split(':').includes(o)),
113
+ matches,
114
+ });
111
115
  if (result.successes.length > 0)
112
116
  return;
113
117
  }
@@ -282,7 +282,7 @@ class Parser {
282
282
  const flagTokenMap = this.mapAndValidateFlags();
283
283
  const flagsWithValues = await Promise.all(Object.entries(this.input.flags)
284
284
  // we check them if they have a token, or might have env, default, or defaultHelp. Also include booleans so they get their default value
285
- .filter(([name, flag]) => flag.type === 'boolean' || flag.env || flag.default || 'defaultHelp' in flag || flagTokenMap.has(name))
285
+ .filter(([name, flag]) => flag.type === 'boolean' || flag.env || flag.default !== undefined || 'defaultHelp' in flag || flagTokenMap.has(name))
286
286
  // match each possible flag to its token, if there is one
287
287
  .map(([name, flag]) => ({ inputFlag: { name, flag }, tokens: flagTokenMap.get(name) }))
288
288
  .map(fws => addValueFunction(fws))
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@oclif/core",
3
3
  "description": "base library for oclif CLIs",
4
- "version": "2.9.2",
4
+ "version": "2.9.4",
5
5
  "author": "Salesforce",
6
6
  "bugs": "https://github.com/oclif/core/issues",
7
7
  "dependencies": {