Differences

This shows you the differences between the selected revisions of the page.

2014-08-28 2014-11-21
fix chown example, reduce example count (martin) suppressing errors (martin)
Line 140: Line 140:
  * ''/u'' - Prevents WinMerge from adding either path (left or right) to the Most Recently Used (MRU) list.   * ''/u'' - Prevents WinMerge from adding either path (left or right) to the Most Recently Used (MRU) list.
 +===== Suppressing Errors =====
 +
 +WinSCP will display error message, when the custom command returns exit code different than 0 or 1; or prints a message on error output, but no normal output.
 +
 +To suppress the error message:
 +
 +  * Redirect error output to ''/dev/null'', to discard it: \\ <code>
 +command_that_prints_non_interesting_progress_on_error_output > /dev/null</code>
 +  * Redirect error output to standard output, to see it in terminal, but avoid error message: \\ <code>
 +command_that_prints_interesting_info_on_error_output 2>&1</code>
 +  * Use ''|| true'' to discard exit code: \\ <code>
 +command_that_returns_255_code || true</code>
 +  * Or combine these together: <code>
 +command_that_prints_interesting_info_on_error_output_and_returns_255_code 2>&1 || true</code>

Last modified: by martin