java - Using Jsch to run confirmable commands in CLI -
is there way use jsch execute command requires confirmation, following one:
>reboot please confirm (y/n)? y
didn't find answer on or documentation on how it. tried execute "reboot", read output till "(y/n)?" faced , printing "y" stream. though, no luck far.
have tried writing outputstream getoutputstream() on channelexec after reading inputstream , waiting phrase 'please confirm...'?
Comments
Post a Comment