Differences
This shows you the differences between the selected revisions of the page.
2011-07-30 | 2011-07-31 | ||
sftp scp ftp (martin) | splitting (martin) | ||
Line 1: | Line 1: | ||
====== Script Commands ====== | ====== Script Commands ====== | ||
- | In its [[scripting|scripting]] functionality, WinSCP supports set of commands described below. | + | ~~SPLIT~~ |
- | + | ||
- | You can see the very same help for the commands as shown here, if you type command ''[[script_commands#help|help <command>]]'' directly in console. | + | |
- | + | ||
- | ===== [[syntax]] General Syntax ===== | + | |
- | Command parameters that include space(s) have to be enclosed in double-quotes. To use double-quote literally, double it: | + | |
- | <code winscp> | + | |
- | put "file with spaces and ""quotes"".html" | + | |
- | </code> | + | |
- | + | ||
- | You can use environment variables in the commands, with syntax ''%NAME%'' ((Generally do enclose reference to double-quotes to cope properly with spaces in its value.)): | + | |
- | <code winscp> | + | |
- | put "%FILE_TO_UPLOAD%" | + | |
- | </code> | + | |
- | + | ||
- | You can reference script arguments (passed on command-line using parameter ''[[commandline#scripting|/parameter]]'') using syntax ''%N%'', where ''N'' is ordinal number of argument ((Generally do enclose reference to double-quotes to cope properly with spaces in its value.)): | + | |
- | <code winscp> | + | |
- | put "%1%" | + | |
- | </code> | + | |
- | + | ||
- | Note that WinSCP treats filenames in case sensitive manner. So even if your server treats filenames in case insensitive manner, make sure you specify case properly((This is important particularly for FTP sessions.)). | + | |
===== call ===== | ===== call ===== |