Skip to content

Commit

Permalink
Merge pull request #19 from jhirbour/master
Browse files Browse the repository at this point in the history
Add tab completion for known ssh hostnames.
  • Loading branch information
mathiasbynens committed Sep 17, 2011
2 parents 2866304 + 050165b commit 48bac9e
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion .bash_profile
Original file line number Diff line number Diff line change
Expand Up @@ -6,4 +6,8 @@ for file in bash_prompt exports aliases functions extra; do
done

# Case-insensitive globbing (used in pathname expansion)
shopt -s nocaseglob
shopt -s nocaseglob

# auto complete ssh host names (the crap between ` and ` just has to be a list... you could just make a list of hosts....
complete -W "$(echo `grep ^Host ~/.ssh/config |sed -e 's/Host //g'| grep -v "*"`;)" ssh

0 comments on commit 48bac9e

Please sign in to comment.