aboutsummaryrefslogtreecommitdiff
path: root/bash/bash_completion.d/sftp.bash
blob: 60044e41293ee27df31bb4df6cc591109b807b7d (plain)
1
2
3
4
5
6
7
8
9
10
# Completion for sftp(1) with ssh_config(5) hostnames
declare -F _ssh_config_hosts >/dev/null ||
    source "$HOME"/.bash_completion.d/_ssh_config_hosts.bash

# bashdefault requires Bash >=3.0
if ((BASH_VERSINFO[0] >= 3)) ; then
    complete -F _ssh_config_hosts -o bashdefault -o default sftp
else
    complete -F _ssh_config_hosts -o default sftp
fi