* Fix default Alt+W keybinding
The old keybinding would chop off the last line of the `whatis` output
when using a multi-line prompt. This fix corrects that.
* Make variable local and remove unneeded if statement
* Test that token is non-empty
1. Added missing commands and arguments.
2. Removed alternative spelling of some commands (e.g. clear-cache|clearcache) since a choice of spelling is not really useful for completion.
3. Fixed a typo: np-ansi → no-ansi.
4. Removed redundant backslash in front of $COMPOSER_HOME.
The updated completion was initially generated using the bamarni/symfony-console-autocomplete package and then incorporated into the existing code.
Reproducer: type `: \<RET><M-p>`. This used to print an error due to builtin test receiving
too many arguments.
It looks like (commandline -j) can return multiple items, because a job can be broken up in multiple
lines terminated by backslashes.
With the new support for self-insert inserting a bound sequence,
the default binding for space as expanding abbreviations can be simplified
to just `self-insert expand-abbr`. This also fixes the bug where space
would cancel pager search.
This commit makes git completions aware of files that are both staged as renamed, and have unstaged
modifications/are deleted.
__fish_git_files now potentially prints these files twice:
$ __fish_git_files renamed modified
foo Renamed file
foo Modified file
Fixes#6031
By not manipulating each line or even each file at a time, we can go
back to `string` and piece together a pipeline that will execute
significantly faster than shelling out to `awk` will. This also removes
one of the few dependencies on `awk` in the codebase.
With this change, `__fish_print_hostnames` now finishes ~80% faster than
it used to a few commits back.
Reordering the `getent hosts` and read from `/etc/hosts` combined with
minimizing shelling and job invocations for parsing the output results
in a profiled and benchmarked ~42% decrease in the time it takes to run,
and that's on a machine with a very small hosts list in the first place.
This update also fixes the hadling of IPv6 addresses in the hosts
output, which were previously ignored, and ignores 127.* loopback
addresses in addition to the 0.0.0.0 address (plus adds support for
shorter IPv4 notations).