mirror of
https://github.com/fish-shell/fish-shell
synced 2024-12-27 05:13:10 +00:00
7784a5f23c
This is really the only important place we're using it. See #5553.
10 lines
423 B
Fish
10 lines
423 B
Fish
#
|
|
# This function is used internally by the fish command completion code
|
|
#
|
|
|
|
function __fish_describe_command -d "Command used to find descriptions for commands"
|
|
command -sq apropos; or return
|
|
# Some systems could use -s 1,8 here, but FreeBSD doesn't have that.
|
|
apropos $argv 2>/dev/null | string replace -rf '^(\S+) \(\S+\)\s+- (.*)' '$1\t$2' \
|
|
| string match (string replace -a '*' '\*' -- "$argv")"*"
|
|
end
|