Differences
This shows you the differences between the selected revisions of the page.
2008-04-11 | 2008-04-11 | ||
4.1 bug 59 (martin) | 4.1 -delete for synchronize and keepuptodate (obsoletes option synchdelete) (martin) | ||
Line 115: | Line 115: | ||
keepuptodate [ <local directory> [ <remote directory> ] ] | keepuptodate [ <local directory> [ <remote directory> ] ] | ||
- | When directories are not specified, current working directories are synchronized. To stop watching for changes press ''Ctrl-C''. Obsolete files are deleted, if [[script_commands#option|option]] ''synchdelete'' is on. | + | When directories are not specified, current working directories are synchronized. To stop watching for changes press ''Ctrl-C''. |
Note: Overwrite confirmations are always off for the command. | Note: Overwrite confirmations are always off for the command. | ||
- | Effective [[script_commands#option|options]]: ''transfer'', ''synchdelete'', ''exclude'', ''include'' | + | Switches: |
+ | ^ Switch ^ Description ^ | ||
+ | | ''-delete''··············| Delete obsolete files | | ||
+ | |||
+ | Effective [[script_commands#option|options]]: ''transfer'', ''exclude'', ''include'' | ||
Examples: | Examples: | ||
<code winscp> | <code winscp> | ||
+ | keepuptodate -delete | ||
keepuptodate d:\www /home/martin/public_html | keepuptodate d:\www /home/martin/public_html | ||
- | keepuptodate | ||
</code> | </code> | ||
test | test | ||
Line 245: | Line 249: | ||
| ''confirm'' | ''%%on|off%%'' \\ Toggles confirmations (overwrite, etc.). \\ Commands affected: ''[[script_commands#get|get]]'', ''[[script_commands#put|put]]'' | | | ''confirm'' | ''%%on|off%%'' \\ Toggles confirmations (overwrite, etc.). \\ Commands affected: ''[[script_commands#get|get]]'', ''[[script_commands#put|put]]'' | | ||
| ''transfer'' | ''%%binary|ascii|automatic%%'' \\ [[transfer_mode|Transfer mode]]: binary, ascii (text), automatic (by extension). \\ Commands affected: ''[[script_commands#get|get]]'', ''[[script_commands#put|put]]'', ''[[script_commands#synchronize|synchronize]]'', ''[[script_commands#keepuptodate|keepuptodate]]'' | | | ''transfer'' | ''%%binary|ascii|automatic%%'' \\ [[transfer_mode|Transfer mode]]: binary, ascii (text), automatic (by extension). \\ Commands affected: ''[[script_commands#get|get]]'', ''[[script_commands#put|put]]'', ''[[script_commands#synchronize|synchronize]]'', ''[[script_commands#keepuptodate|keepuptodate]]'' | | ||
- | | ''synchdelete'' | ''%%on|off%%'' \\ Should obsolete files be deleted during [[task_synchronize|synchronization]]? \\ Commands affected: ''[[script_commands#synchronize|synchronize]]'', ''[[script_commands#keepuptodate|keepuptodate]]'' | | ||
| ''exclude'' \\ ''include'' | ''%%clear | <mask>[;<mask2>...]%%'' \\ Sets [[ui_transfer#other_options|exclusion or inclusion]] [[file_mask|masks]] (only one can be set at time). \\ Commands affected: ''[[script_commands#get|get]]'', ''[[script_commands#put|put]]'', ''[[script_commands#synchronize|synchronize]]'', ''[[script_commands#keepuptodate|keepuptodate]]'' | | | ''exclude'' \\ ''include'' | ''%%clear | <mask>[;<mask2>...]%%'' \\ Sets [[ui_transfer#other_options|exclusion or inclusion]] [[file_mask|masks]] (only one can be set at time). \\ Commands affected: ''[[script_commands#get|get]]'', ''[[script_commands#put|put]]'', ''[[script_commands#synchronize|synchronize]]'', ''[[script_commands#keepuptodate|keepuptodate]]'' | | ||
Line 334: | Line 337: | ||
When directories are not specified, current working directories are synchronized. | When directories are not specified, current working directories are synchronized. | ||
- | Obsolete files are deleted, if [[script_commands#option|option]] ''synchdelete'' is on. Note: Overwrite confirmations are always off for the command. | + | Note: Overwrite confirmations are always off for the command. |
Switches: | Switches: | ||
^ Switch ^ Description ^ | ^ Switch ^ Description ^ | ||
+ | | ''-delete'' | Delete obsolete files | | ||
| ''-mirror'' | [[task_synchronize_full#synchronization_mode|Mirror mode]] (synchronize also older files). Ignored for ''both''. | | | ''-mirror'' | [[task_synchronize_full#synchronization_mode|Mirror mode]] (synchronize also older files). Ignored for ''both''. | | ||
| ''-criteria=<criteria>'' | [[ui_synchronize#comparison_criteria|Comparison criteria]]. Possible values are ''time'', ''size'' and ''both''. Ignored for ''both'' mode. | | | ''-criteria=<criteria>'' | [[ui_synchronize#comparison_criteria|Comparison criteria]]. Possible values are ''time'', ''size'' and ''both''. Ignored for ''both'' mode. | | ||
- | Effective [[script_commands#option|options]]: ''transfer'', ''synchdelete'', ''exclude'', ''include'' | + | Effective [[script_commands#option|options]]: ''transfer'', ''exclude'', ''include'' |
Examples: | Examples: | ||
<code winscp> | <code winscp> | ||
- | synchronize remote | + | synchronize remote -delete |
synchronize both d:\www /home/martin/public_html | synchronize both d:\www /home/martin/public_html | ||
</code> | </code> | ||