Using SSH.Net I would like to do the following: Make a command to check if the file exists on a Linux Machine via C# and various ssh packages and/or winscp libraries and if the file or files do not exist on the linux machine, then it will create them, I enjoy the educational aspects of programming, so I am improving ones self, I apologise for not fully writing out the question.
private void TestCommmand(string ip, int port, string uname, string pw)
{
    // [1]
    SshClient cSSH = new SshClient(ip, port, uname, pw);
    cSSH.Connect();
    SshCommand x = new SshCommand();
    // [2] here is where the Check needs to happen
    //
    if (condition == true)
    {
        x = cSSH.RunCommand(" mkdir /var/www/html/app/cs");
    }
    else // if condition is false
    {
        cSSH.Disconnect();
        cSSH.Dispose();
    }
    //
}
 
     
     
    