We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent a31b10c commit a5a13eeCopy full SHA for a5a13ee
bin/package-manager-completion.ts
@@ -129,6 +129,16 @@ export class PackageManagerCompletion extends RootCommand {
129
const knownCommands = [...this.commands.keys()];
130
131
if (!knownCommands.includes(potentialCliName)) {
132
+ const matchesKnownPrefix = knownCommands.some((cmd) =>
133
+ cmd.startsWith(potentialCliName)
134
+ );
135
+
136
+ // If the token matches the start of a known command, let the built-in
137
+ // command completion handle it instead of treating it as an external CLI.
138
+ if (matchesKnownPrefix) {
139
+ return super.parse(args);
140
+ }
141
142
const cliArgs = normalizedArgs.slice(1);
143
const suggestions = await getCliCompletions(
144
potentialCliName,
0 commit comments