New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat(completion): print completion code to stdout #7597
Conversation
The referenced issue mentions that helm and kubectl use the |
actually, that would conflict with the |
I suspect |
I'm fine either way. |
npm has a But it is also not super important, so I don't know. |
@zkochan I guess we can redirect |
But should we though? Overloading functionalities doesn't look maintainable in the long run. |
Besides, I think |
No, npm uses |
So this would still requires changes on tabtab codebase after all. The tabtab codebase is kind of a mess right now, tests failing left and right. |
I guess, the command that tabtab executes can be renamed to something else, like |
* switch to provided type declarations * fix typings * update tests * update bundle scripts
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@zkochan I require your inputs.
I have renamed |
8f03869
to
6ae45a0
Compare
64406ed
to
061bd0b
Compare
061bd0b
to
738c090
Compare
Just `pnpm completion` is enough
The commands |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't think 2 plugins packages are needed. All the completion related commands can be in one package.
completion/plugin-commands-completion-server/src/getOptionType.ts
Outdated
Show resolved
Hide resolved
I have merged |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The changesets don't describe all the changes.
pnpm/src/pnpm.ts
Outdated
@@ -15,8 +15,13 @@ const argv = process.argv.slice(2) | |||
break | |||
} | |||
case 'install-completion': { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
you said you'll remove install-completion and uninstall-completion
from the commands.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I converted them to plugins then forgot to remove them here. When I remove them, I completely forgot to remove the switch block.
Resolves #3083
Unlike
install-completion
which would write files to the filesystem for you,completion
only prints the code for completion to stdout. It is the responsibility of the user to convert the code in the stdout to a completion file andsource
them from their login shell.Usage Example: Create completion script for ZSH and
source
them from.zshrc