5

bash script - sftpbatchfile - stop on failure

view full story
linux-howto

http://www.unix.com – Hello all, I am currently writing a script to send files to a server over sftp. When the sftp put command succeeds it wil preform a local move from within the sftp shell to another folder (this is done so when the script is rerun no doubles will be sent). therefore i had following sollution Code: for FILE in `ls -tr $tbtsftp`; do     echo "put "$FILE     echo "cd "$remotepath_VAN >> $commandlist     echo "put "$FILE >> $commandlist     echo "!echo STOP > "$SFTPCHECK_PUT_RM >> $commandlis (HowTos)