Differences
This shows you the differences between the selected revisions of the page.
scriptcommand_put 2023-11-11 | scriptcommand_put 2024-10-26 (current) | ||
Line 2: | Line 2: | ||
[[task_upload|Uploads]] one or more files from local directory to remote directory. | [[task_upload|Uploads]] one or more files from local directory to remote directory. | ||
- | ==== Syntax ===== | + | ===== Syntax ===== |
put <file> [ [ <file2> ... ] <directory>/[ <newname> ] ] | put <file> [ [ <file2> ... ] <directory>/[ <newname> ] ] | ||
Line 25: | Line 25: | ||
| ''-==latest=='' | Uploads the latest file from the files selected by the ''file'', ''file2'' ... parameters (typically [[file_mask|file masks]]) only. | | | ''-==latest=='' | Uploads the latest file from the files selected by the ''file'', ''file2'' ... parameters (typically [[file_mask|file masks]]) only. | | ||
| ''-==resume=='' | Automatically resume transfer if possible.((Applies for individual files transfers only. It does not skip transfer of fully transferred files. For that, combine the switch with ''[[#neweronly|-neweronly]]''.)) \\ [[SFTP]] and [[FTP]] protocols only. Cannot be combined with ''[[#append|-append]]''. Has no effect when streaming (''-'' source). | | | ''-==resume=='' | Automatically resume transfer if possible.((Applies for individual files transfers only. It does not skip transfer of fully transferred files. For that, combine the switch with ''[[#neweronly|-neweronly]]''.)) \\ [[SFTP]] and [[FTP]] protocols only. Cannot be combined with ''[[#append|-append]]''. Has no effect when streaming (''-'' source). | | ||
- | | ''-==append=='' | Append source file to the end of target file. \\ [[sftp|SFTP protocol]] only. Cannot be combined with ''[[#resume|-resume]]''. //When combined with streaming (''-'' source), is is supported by the latest beta version only.// &beta | | + | | ''-==append=='' | Append source file to the end of target file. \\ [[sftp|SFTP protocol]] only. Cannot be combined with ''[[#resume|-resume]]''. | |
| ''-==preservetime=='' | Preserve timestamp. | | | ''-==preservetime=='' | Preserve timestamp. | | ||
| ''-==nopreservetime=='' | Do not preserve timestamp. | | | ''-==nopreservetime=='' | Do not preserve timestamp. | | ||
Line 98: | Line 98: | ||
$session.PutFiles("d:\*.txt", "/home/martinp/web/", $True, $transferOptions).Check() | $session.PutFiles("d:\*.txt", "/home/martinp/web/", $True, $transferOptions).Check() | ||
$session.PutFiles("d:\*.xml", "/home/martinp/web/", $True, $transferOptions).Check() | $session.PutFiles("d:\*.xml", "/home/martinp/web/", $True, $transferOptions).Check() | ||
- | </code> = | + | </code> |