Skip to content
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

fix: coTopics completion #431

Open
wants to merge 2 commits into
base: main
Choose a base branch
from
Open

fix: coTopics completion #431

wants to merge 2 commits into from

Conversation

jayree
Copy link
Contributor

@jayree jayree commented Feb 23, 2023

Change the behaviour of coTopic completion to complete commands and flags

@git2gus
Copy link

git2gus bot commented Feb 23, 2023

This issue has been linked to a new work item: W-12592066

@jayree jayree marked this pull request as draft February 23, 2023 23:17
@jayree jayree marked this pull request as ready for review March 1, 2023 15:15
@cristiand391
Copy link
Member

Hey @jayree, sorry for the late reply.

I've been testing this and found one issue with _values:

For flags that take a value, _values inserts a = between the flag name and its value , that seems to make _arguments unable to parse the flag and keeps suggesting it after completing the second flag (which shoud only happen if flag.multiple=true).

Top: sfdx with autocomplete using you branch
Bottom: current zsh autocomplete

I've looked at the docs and haven't found any options to change the = sign being inserted (values -s ' ' doesn't work as expected).

If the first flag doesn't have an =, then _arguments is able to parse it (0:28 in the video)

Screen.Recording.2023-04-21.at.13.18.26.mov

Still, IMO, this improves UX vs the current implementation (which makes it hard for new users to discover commands when the id is a coTopic). I'll check with my team again and let you know.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants