* Add eopkg support
Add support for eopkg in __fish_print_packages function, and
add new completion eopkg.fish in share/completions
* Sorry for the empty file
* Sorry for the empty file again
* Use builtin function for checking subcommand and options
* Fix description
* Use string function to replace grep and cut
* Add completion for search command
Turns out "__fish_git_staged_files" does the same thing as "__fish_git_modified_files --staged".
Also use "--staged" instead of "--cached", which is a more
understandable synonym.
Many thanks to @thomcc on gitter.
Running "cut" multiple times in a loop has an adverse performance
impact on first use, especially on slow systems. Using builtin "read"
for the same purpose is faster and cleaner.
for various completions.
This makes the code a bit nicer, removes one of the
__fish_print_hostnames calls (which are slow) and a sed call, thereby
improving performance by about 33% (600ms to 400ms).
Fixes#4511.
fish was indiscriminately calling `rustc -Z help` in the autocompletion
script for `rustc`, but `-Z` (and its `-Z help` output completions) is
only available when using the nightly compiler.
Note that this isn't a perfect fix since if you try to use those command
line options now added to the autocompletions list without using the
nightly toolchain, `rustc` will still throw an error. But at least this
way we don't cause random errors about `-Z` not being available to
appear any time someone tries to use `rustc` from the fish command prompt.
\b does not match "end of spaces" but rather "start of a-z/0-9" and so
does not match the start of string '-c'. Match (and then re-insert) a
literal ' ' as part of the pattern instead.
Work around bug pypa/pip#4755
Don't expect all users to be running a version of pip2/3 that includes
the fix (once it's upstreamed). Will continue to work if/when pip2/3
emit the correct output. pip is already very slow at printing the
completions (see #4448) so the `sed` call overhead is neglible.
* 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
This
- Offers more candidates
- Is more reactive (it'll always incorporate "--state=" and "--type="
- Is faster (about 800ms to about 120ms)
- Needs fewer function files
All __fish_systemctl_* functions except __fish_systemctl_services have
been removed.
j does not have any "logical" source of completions, but it almost often
called with arguments that have been seen before (since it is used to
jump to favorite/recent directories). We can search the history for
possible completions and use those.
This is an example of the behavior mentioned in #4344 as a possible
enhancement for fish 3.0, where completions can be provided from history
if none are otherwise found.
commit e07f1d59c06094846db8ce59f65d4790b222fffa
Author: Mahmoud Al-Qudsi <mqudsi@neosmart.net>
Date: Sun Sep 10 21:54:45 2017 -0500
Use git branch and git branch --remote for checkout completions
commit 9e1632236be065e051e306b11082ca4e9c7a0ee1
Author: Mahmoud Al-Qudsi <mqudsi@neosmart.net>
Date: Sun Sep 10 11:27:30 2017 -0500
Correct classification of remote and local branches
To prevent any breakage, no changes were made to __fish_git_branches,
instead its output was filtered into __fish_git_remote_branches and
__fish_git_local_branches, the two of which are now used to provide
completions for "git checkout ..."
Fixes#4395Closes#4396
It seems that under python3, s3cmd emits its output as a long list (like
ls -l) with or without the --long parameter to "s3cmd ls s3://...".
This patch includes only s3://* paths from that output as completions.
Addresses the main concern of #3830 by preserving the internal ordering
of tag/branch listings generated by git. Fixes mixing of remote and
local branches in completions.
Does not address the concern of having local branches on top, remote
branches after, and tags at the bottom - I don't believe we have that
functionality available to us yet. #361 only implemented sort within a
category of completions, but there is no category "weight" unless I'm
mistaken.