How To Run a Script in WinSCP

user3930361 picture user3930361 · Apr 7, 2015 · Viewed 13k times · Source

I am using winSCP GUI to connect to linux terminal and then copy the files and other stuff.

Now i have some scripts on the UNIX server,I am connected but how to run the script from the Win SCP.

what basically is needed is sh scriptname.sh through the WinSCP.Please let me know if anyone else found out how to do that.AS loging into putty and running the command is time taking for me. WinSCP Custom Command option tried to click on Execute,but the error pops up like no such directory.

Tried google but to the point information is not coming up.

Answer

NeverGiveUp161 picture NeverGiveUp161 · Apr 7, 2015

Try this sh "!"

OR

First of all executing commands from WinSCP can be tricky and if you are able to run few commands also,there are restrictions which you can not do fro WinSCP and should have to ultimately take help of PUTTY.

Here is the link Integrate WinSCP with Putty which will help you integrate your WinSCP to Putty,so that when you open any server through WinSCP putty will automatically connect without even asking for the password.And then you can run you command,hope that wound be of any trouble to you.

Remember you can store the connection details in WinSCP and in just one click it will connect to the server on SCP and also on Putty.