Quantcast
Viewing all articles
Browse latest Browse all 5991

Unix: is there an alternative to expect command? [closed]

I am trying to do a bash script in order to autoconnect into a ssh server.However I don't have permissions to install the expect package.So I would like to know if there is a way to automatically enter "yes" when asked and then enter the password when asked without using the expect command?

I work on xubuntu.

In summary this is what I would like:

#!/bin/shssh user@localhost << EOT#enter "yes" here when asked#enter my password here when askedlsEOT

Viewing all articles
Browse latest Browse all 5991

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>