Differences
This shows you the differences between the selected revisions of the page.
2009-04-14 | 2009-04-17 | ||
guide_automation_advanced for checkign script results (martin) | executables (martin) | ||
Line 80: | Line 80: | ||
* Check exit code of WinSCP (exit code is the only relevant and reliable way to check if script completed successfully). See example below and [[faq_script_result|FAQ]]. | * Check exit code of WinSCP (exit code is the only relevant and reliable way to check if script completed successfully). See example below and [[faq_script_result|FAQ]]. | ||
* Save and inspect log file. [[logging_xml|XML log format]] is recommended. Use [[commandline|command-line]] parameter ''/log''. | * Save and inspect log file. [[logging_xml|XML log format]] is recommended. Use [[commandline|command-line]] parameter ''/log''. | ||
- | * Save and inspect output of the script. Use output redirection (''> filename'' at the end of commandline executing WinSCP). Note that you can redirect output of ''WinSCP.com'' only (see [[scripting#console|documentation]]). | + | * Save and inspect output of the script. Use [[executables|output redirection]]. |
Once you find out what was the result of the script, you can perform any action you like. E.g. after evaluating exit code of WinSCP, you can send a "success" or "error" email. For that use any command-line email client you like, e.g. [[http://glob.com.au/sendmail/|sendmail]]: | Once you find out what was the result of the script, you can perform any action you like. E.g. after evaluating exit code of WinSCP, you can send a "success" or "error" email. For that use any command-line email client you like, e.g. [[http://glob.com.au/sendmail/|sendmail]]: |