Commit Graph

4 Commits

Author SHA1 Message Date
Fabian Homborg
43df5ba828 completions: Stop checking for command existence
Since 4414d5c888 (in fish 3.0.0) we
don't autoload completions if the command doesn't exist.

So there is no need to check inside the scripts anymore.

Whats more, a few (like pip and cabal) checked `command -q` instead of
`type -q`, meaning they'd fail if someone used a function instead of a
command of that name.

If the *command* actually needs to exist, checks like that are still
warranted, like in `npm` where aliasing it to `nvm` is popular.

A teensy additional bit: Make `sysctl -w` the same as `sysctl
--write`. That description was bogus.
2020-05-18 20:48:36 +02:00
Fabian Homborg
d8b1f0715f [pip* completions] Silence stderr
For some reason, these tools print an upgrade message to stderr, even
when stdout goes somewhere else.
2018-05-03 11:32:18 +02:00
Aaron Gyes
d740b2a473 pip completions: use builtin source rather than eval function. 2017-10-04 21:50:09 -07:00
Cristian Prieto
1770e47eb0 Python's pip and pipenv completions (#4448)
* Add pip completion

 * We call native pip completion for fish if pip is installed

* Add pipenv completion

 * We call pipenv native completion if pipenv is installed

* Applied changes as requested by @floam

 * Changed usage of `test (command -v)` for just `command -sq`

* Add completions for pip2/3

 * In some systems pip is not aliased and we have pip2 and pip3
 * In those cases, we just load the completions for those commands

* Separate pip2/3 completions in their own file as requested by @floam
2017-10-04 21:15:41 -07:00