mirror of
https://github.com/fish-shell/fish-shell
synced 2025-01-12 13:08:49 +00:00
Add function __fish_complete_user_at_hosts
This function list hostnames; if commandline hoge@~ , it list hoge@(hostname)
This commit is contained in:
parent
70c9d78536
commit
170f11771b
1 changed files with 5 additions and 0 deletions
5
share/functions/__fish_complete_user_at_hosts.fish
Normal file
5
share/functions/__fish_complete_user_at_hosts.fish
Normal file
|
@ -0,0 +1,5 @@
|
|||
function __fish_complete_user_at_hosts -d "Print list host-names with user@"
|
||||
for user_at in (commandline -ct | string match -r '.*@'; or echo "")(__fish_print_hostnames)
|
||||
echo $user_at
|
||||
end
|
||||
end
|
Loading…
Reference in a new issue