Topic "Multiple-line Commands"

Author Message
adem

Guest


Hi,

Is there a way to enter more than one command line in Preferences | Commands menu?

This is what I want to do, if I can:_

<COMMANDS>
#go to squidGuard db folder
cd /usr/local/squidGuard/db/

#make sure that all files are owned by Squid
chown -R squid.squid *

#stop Squid
/etc/rc.d/init.d/squid stop

#Re-compiling config files:
su squid
/usr/local/squidGuard/bin/squidGuard -C all -d
exit

#start Squid
/etc/rc.d/init.d/squid start
</COMMANDS>

Can it be done?

TVMIA,

Cheers,
Adem
martin
[View user's profile]
Site Admin
Joined: 2002-12-10
Posts: 25015
Location: Prague, Czechia
I'm not expert for UNIX shells, but I believe that you can separate multiple commands with semicolon (Wink.

However you cannot execute su, or at least most of the servers does not allow this for non-interactive sessions.
_________________
Martin Prikryl
Advertisements

You can post new topics in this forum






Search Site

What is WinSCP?

It is award-winning SFTP client, SCP client, FTPS client and FTP client integrated into one software program for file transfer to FTP server or secure SFTP server. [More]

And it's free!

Donate

About donations

$9   $19   $49   $99

About donations

Recommend

WinSCP Privacy Policy

WinSCP License