fzf/shell
Christoph Anton Mitterer f1d306feab [shell] move username prefixing code where needed
`__fzf_list_hosts()` seems like a function a user may want to override with some
custom code.
For that reason it should be kept as simple as possible, that is printing only
hostnames, one per line, optionally in some sorting.

The handling of adding a `username@` (which is then the same for each line), if
any, would unnecessarily complicate that for people who want to override the
function.
Therefore this commit moves that to the places where it's actually used (as of
now only `_fzf_complete_ssh()`).

This also saves any such handling for `_fzf_host_completion()`, where this isn’t
needed at all.

Right now it comes at a cost, namely an extra invocation of `awk` in the
`_fzf_complete_ssh()`-case.
However, it should be easily possible to improve `__fzf_list_hosts()` to no
longer need the final `awk` in the pipeline there.

Signed-off-by: Christoph Anton Mitterer <mail@christoph.anton.mitterer.name>
2023-10-12 20:44:25 +09:00
..
completion.bash [shell] move username prefixing code where needed 2023-10-12 20:44:25 +09:00
completion.zsh [shell] move username prefixing code where needed 2023-10-12 20:44:25 +09:00
key-bindings.bash [bash] Use command to “protect” further commands (#3462) 2023-10-11 13:07:47 +09:00
key-bindings.fish [shell] don’t needlessly escape . in shell pattern 2023-09-24 13:23:40 +09:00
key-bindings.zsh Improve interactiveness checks (#3449) 2023-10-09 01:19:28 +09:00