Differences

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

2015-01-13 2015-02-18
/batchsettings is a standalone parameter. so no brackets (martin) 5.7 Logging level and password logging can be set on command-line using /loglevel switch. (martin)
Line 16: Line 16:
winscp.exe [mysession] [/rawsettings setting1=value1 setting2=value2 ...] winscp.exe [mysession] [/rawsettings setting1=value1 setting2=value2 ...]
winscp.exe [/console] [/script=script_file] [/command command1 command2 ...] [/parameter param1 ...] winscp.exe [/console] [/script=script_file] [/command command1 command2 ...] [/parameter param1 ...]
-winscp.exe [/ini=<inifile>] [/log=<logfile>] [/xmllog=<logfile> [/xmlgroups]]+winscp.exe [/log=<logfile> ·[/loglevel=<level>]] [/xmllog=<logfile> [/xmlgroups]
 +winscp.exe [/ini=<inifile>]
winscp.exe [/rawconfig config1=value1 config2=value2 ...] winscp.exe [/rawconfig config1=value1 config2=value2 ...]
winscp.exe /batchsettings <site_mask> setting1=value1 setting2=value2 ... winscp.exe /batchsettings <site_mask> setting1=value1 setting2=value2 ...
Line 26: Line 27:
<code batch> <code batch>
winscp.com [/script=script_file] [/command command1 command2 ...] [/parameter param1 ...] winscp.com [/script=script_file] [/command command1 command2 ...] [/parameter param1 ...]
-winscp.com [/ini=<inifile>] [/log=<logfile>] [/xmllog=<logfile> [/xmlgroups]] [/nointeractiveinput]+winscp.com [/log=<logfile> [/loglevel=<level>]] [/xmllog=<logfile> [/xmlgroups]] [/nointeractiveinput
 +winscp.exe [/ini=<inifile>]
winscp.exe [/rawconfig config1=value1 config2=value2 ...] winscp.exe [/rawconfig config1=value1 config2=value2 ...]
winscp.com /help winscp.com /help
Line 63: Line 65:
==== [[logging]] Logging ==== ==== [[logging]] Logging ====
-With ''/log'' parameter you may turn on [[logging|session logging]] to file specified by [[local_path|local path]]. With ''/xmllog'' parameter you may turn on [[logging_xml|XML logging]] to file specified by local path. ((For backward compatibility, XML logging can also be enabled using ''/log'' parameter with filename ending with ''.xml'' extension.)) In either path you can use the same patterns as in the [[ui_pref_logging|logging preferences]].+With ''/log'' parameter you may turn on [[logging|session logging]] to file specified by [[local_path|local path]]. 
 + 
 +Use parameter ''/loglevel'' to change logging level. The value can be in range ''0''..''2'' (for //Normal//, //Debug 1// and //Debug 2// logging levels respectively). Append additional ''*'' to enable password logging (e.g. ''/loglevel=2*''). &recent_feature(5.7) 
 + 
 +With ''/xmllog'' parameter you may turn on [[logging_xml|XML logging]] to file specified by local path. ((For backward compatibility, XML logging can also be enabled using ''/log'' parameter with filename ending with ''.xml'' extension.)) In either path you can use the same patterns as in the [[ui_pref_logging|logging preferences]]
 + 
 +Use parameter ''/xmlgroups'' along with ''/xmllog'', to [[logging_xml#group|group]] all XML log elements belonging to the same command under parent ''group'' element.
<code batch> <code batch>
-winscp.exe sftp://martin@example.com/ /log="C:\winscp.log"+winscp.exe sftp://martin@example.com/ /log="C:\winscp.log" /loglevel=0
</code> </code>
Line 79: Line 87:
With ''[[executables|winscp.exe]]'', if ''/console'' parameter is not used along with ''/script'' or ''/command'', the script/command is executed without visual feedback (window). With ''[[executables|winscp.exe]]'', if ''/console'' parameter is not used along with ''/script'' or ''/command'', the script/command is executed without visual feedback (window).
- 
-Use parameter ''/xmlgroups'' along with ''/xmllog'', to [[logging_xml#group|group]] all XML log elements belonging to the same command under parent ''group'' element. 
Use parameter ''/nointeractiveinput'', when feeding commands to ''[[executables|winscp.com]]'' using [[executables#redirection|standard input]], to make sure prompts for anything other than commands (such as password prompts) are cancelled. Also prevents error message popping up when fatal error occurs while starting WinSCP. When combined with ''/xmllog'' the fatal error is recorded in the %%XML%% log (&beta_feature) Use parameter ''/nointeractiveinput'', when feeding commands to ''[[executables|winscp.com]]'' using [[executables#redirection|standard input]], to make sure prompts for anything other than commands (such as password prompts) are cancelled. Also prevents error message popping up when fatal error occurs while starting WinSCP. When combined with ''/xmllog'' the fatal error is recorded in the %%XML%% log (&beta_feature)

Last modified: by martin – Currently locked by: 176.125.229.20