Bash script that uses autocomplete from the ssh/config file for autocomplete

Viewed 30

So here's my idea. I have a script that's runs ssh $hostname 'command' But instead of having to type out the hostname, I would like to import the list of hosts from the .ssh/config file. AS of now I did that by importing them into an array, but I don't have a way to autocomplete the hostnames. This would be better since there are more than 50 and I cannot remember them all.

Thanks in advance

0 Answers
Related