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

complete -e doesn't #380

Closed
zanchey opened this issue Nov 7, 2012 · 8 comments
Closed

complete -e doesn't #380

zanchey opened this issue Nov 7, 2012 · 8 comments
Labels
Milestone

Comments

@zanchey
Copy link
Member

@zanchey zanchey commented Nov 7, 2012

The documentation for complete says:

"When erasing completions, it is possible to either erase all completions for a specific command by specifying complete -e -c COMMAND, or by specifying a specific completion option to delete by specifying either a long, short or old style option."

The former doesn't work, but that latter does.

> complete -c foo -l bar
> foo --b<TAB>ar
> complete -c foo -e
> foo --b<TAB>ar
> complete -e -c foo
> foo --b<TAB>ar
> complete -c foo -e -l bar
> foo --b<TAB><BELL>
@dolmen
Copy link

@dolmen dolmen commented Jul 8, 2013

The bug is still present in 07b7a65.
Here is how to reproduce:

> complete | grep foo
> complete -c foo -A -f -a 'bar baz'
> complete | grep foo
complete --no-files --command foo --arguments 'bar baz'
> complete -c foo -e
> complete | grep foo
complete --no-files --command foo --arguments 'bar baz'

At least the documentation should be fixed to avoid mentionning -e until it works (or point to this issue).

@xfix
Copy link
Member

@xfix xfix commented Jul 9, 2013

@dolmen: Nobody said it's fixed. The bug is still open.

@davidxia
Copy link
Contributor

@davidxia davidxia commented Jun 30, 2014

Just tested on version 2.1.0-660-g1cfd055 with above 2 repro steps. Still exists.

@xfix
Copy link
Member

@xfix xfix commented Jun 30, 2014

The reports that this bug still exists aren't needed. It's already known.

@lilyball
Copy link
Member

@lilyball lilyball commented Sep 2, 2014

The -e flag seems rather broken in general. Here's what I've found in a quick test:

  • complete -c foo -l bar -e erases all long option completions for foo, not just bar
  • complete -c foo -s a -e segfaults if there's multiple short options associated with foo
  • The code for -e makes no distinction between old-style and gnu-style long options when erasing, although this is kind of moot right now due to the first point.
@lilyball lilyball closed this in 2820c7a Sep 2, 2014
@lilyball lilyball modified the milestones: next-minor, fish-future Sep 2, 2014
@scooter-dangle
Copy link

@scooter-dangle scooter-dangle commented Apr 22, 2015

I had earlier installed fish from master to get completion erasure, but I thought it was included in 2.1.2, which I used brew to install when it came out. The fix doesn't seem to be present...any word on when it will be included in an official release?

@zanchey
Copy link
Member Author

@zanchey zanchey commented Apr 30, 2015

It will not be in 2.1.2 - that was a bugfix on the 2.1 branch. It's included in the upcoming 2.2 release.

@scooter-dangle
Copy link

@scooter-dangle scooter-dangle commented May 4, 2015

gotcha...thanks for the response

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Apr 18, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
6 participants
You can’t perform that action at this time.