Setting your shell prompt
Top  Previous  Next

The correct shell prompt is needed by the SshSession class in order to know when the SSH server is ready to accept data. By default the shell prompt is "$". If the shell prompt on your server is different than the default shell prompt then you will need to change this value in the SshSession instance prior to establishing a connection.

Example


// set the shell prompt expected from server      
session.setShellPrompt("
#");