Commit Graph

  • e844be4e7b - Use read_short() and write_short(). - If the user does not want itemized changes, don't log the name for attribute changes. Wayne Davison 2005-02-18 20:17:24 +00:00
  • 88b218fa5c - Tweaked code in itemize() a bit. - Use the new write_short() function. - Mention the delete() when an item replaces an item of a different type. - Make sure that this replacing of a non-same item is marked as a new transfer in the itemized output. Wayne Davison 2005-02-18 20:17:20 +00:00
  • e66d70e34c The '%n' escape needs to append a trailing slash onto a directory name. Wayne Davison 2005-02-18 20:17:17 +00:00
  • 9361f83933 Added read_short() and write_short(). Wayne Davison 2005-02-18 20:17:15 +00:00
  • 3b2bebbf90 Improved the "log format" section some more. Wayne Davison 2005-02-18 20:17:12 +00:00
  • 4f90eb433a Improved --verbose, --itemize-changes, and --log-format. Wayne Davison 2005-02-18 20:17:09 +00:00
  • b485e0c16c Fixed/improved the comment before safe_name(). Wayne Davison 2005-02-18 20:17:05 +00:00
  • bc1fac9648 Handle uchar and short as a function return type. Wayne Davison 2005-02-18 20:16:59 +00:00
  • c78779cce3 - Fixed a few bugs and compile warnings. - Use the long-option parser for better option handling. - Output a usage message if the options are wrong. - Improved the option-variable names. - Parse the new default daemon log-file format. - Handle filenames that have spaces in them. Wayne Davison 2005-02-18 17:58:03 +00:00
  • 702cd15cb0 For the server, don't ever intuit verbosity higher than what the client asked for. Wayne Davison 2005-02-18 17:36:12 +00:00
  • 1da05366ad The daemon loop needs to call log_open() because it called log_close(). Wayne Davison 2005-02-18 17:34:09 +00:00
  • 2267efeac5 Made log_open() non-static and moved log_close() next to it. Wayne Davison 2005-02-18 17:33:43 +00:00
  • 15954da08f Updated the default "log format" string and the output of "%i". Wayne Davison 2005-02-17 09:19:07 +00:00
  • b2dc7bad39 Changed the default log format. Wayne Davison 2005-02-17 09:16:51 +00:00
  • d4e0196346 Use '.' for unchanged attributes in the %i output. Wayne Davison 2005-02-17 09:16:23 +00:00
  • 2fc50f5a98 More improvements for the description of the %i output. Wayne Davison 2005-02-16 20:12:20 +00:00
  • bd5b85dbc7 Mention the new flag-word for protocol 29. Wayne Davison 2005-02-16 17:08:04 +00:00
  • 8a8324657e - The itemized flags are now 2 bytes instead of 1. - Always send/receive the itemized flags for protocols >= 29. - The output of the verbose log-the-transfer messages is always handled via log_send() (when we're the client). Wayne Davison 2005-02-16 17:02:16 +00:00
  • 4bb0af79b7 - The itemized flags are now 2 bytes instead of 1. - Always send/receive the itemized flags for protocols >= 29. - The output of the verbose log-the-transfer messages is always handled via log_recv() (when we're the client). Wayne Davison 2005-02-16 17:02:13 +00:00
  • e3bcd89319 - The itemized flags are now 2 bytes instead of 1. - Always send the itemized flags for protocols >= 29. - Sent an itemized-flag update for dirs and symlinks for protocols >= 29 (instead of outputting a message directly). Wayne Davison 2005-02-16 17:02:11 +00:00
  • 87383697e8 - Auto-set --verbose if --dry-run is specified w/o --log-format. - When verbose w/o a log_format specified, set it to "%n%L". - There's no longer a need to send -i to the server. Wayne Davison 2005-02-16 17:02:08 +00:00
  • e4b808989e Moved the auto-setting of --verbose when --dry-run is specified into options.c. Wayne Davison 2005-02-16 17:02:05 +00:00
  • 59e52bf276 Tweaked ITEM_MISSING_DATA. Wayne Davison 2005-02-16 17:02:02 +00:00
  • 9b40e44ef4 No need to handle itemize_changes anymore. Wayne Davison 2005-02-16 17:01:59 +00:00
  • e92f21d2f7 Tweaked the mention of --itemize-changes. Wayne Davison 2005-02-16 08:12:34 +00:00
  • 910e89b963 - We now accept an itemized-changes flag-byte over the socket if we're the local client and --itemized-changes was specified. If the item is not being updated, just call log_recv(). - We reject an attempt to file-update any non-regular file, not just dirs. - Avoid the verbose "log the transfer" output if --log-format was specified and log_before_transfer is in effect. - Call log_recv() with its new iflags arg. Wayne Davison 2005-02-16 08:10:45 +00:00
  • 8a9cfb2459 - We now accept an itemized-changes flag byte over the socket if we're in --itemized-changes mode. If the item is not being updated, either pass it along to the receiver (if we're the server) or just call log_send(). - We reject an attempt to file-update any non-regular file, not just dirs. - Avoid the verbose "log the transfer" output if --log-format was specified and log_before_transfer is in effect. - Call log_send() with its new iflags arg. Wayne Davison 2005-02-16 08:10:41 +00:00
  • 41961db0bd Ensure that -i is set consistent with the batch's data. Wayne Davison 2005-02-16 08:10:38 +00:00
  • e76518843d - If log_before_transfer is possible, don't force --verbose on for --progress. - If --log-format contains %i, set --itemize-changes (-i). - Always send -i to the remote rsync if it was specified/implied. Wayne Davison 2005-02-16 08:10:31 +00:00
  • ef74f5d626 - Improved log_formatted() to handle long filenames better. - Added %i, for the list of itemized changes, %n for the normal filename (might be shorter than %f), and %L for a " -> symlink" string IIF the item is a symlink (else ""). - The log_{send,recv}() functions now take an "iflags" arg. Wayne Davison 2005-02-16 08:10:28 +00:00
  • c557eb8cec Changed showchg() into itemize(), which now ships off a flag byte of what changed over to the sender instead of outputting a string itself. This does mean that we now ship off indexes of non-file items that got updated, but the sender will know what to do with it. Wayne Davison 2005-02-16 08:10:25 +00:00
  • 0cc279e0d3 - Added the new ITEM_* flags for the itemized-changes flag passing. - Also added defines for FLAG_SENT and MSG_SUCCESS. Wayne Davison 2005-02-16 08:10:22 +00:00
  • 0cfdf22655 Documented that -i now sets a default --log-format string. Wayne Davison 2005-02-16 08:10:19 +00:00
  • 527a010f10 Documented the new log-format escapes: %n, %L, and %i. Wayne Davison 2005-02-16 08:10:13 +00:00
  • c8ca974634 Some tweaks to how --itemize-changes works. Wayne Davison 2005-02-16 01:13:03 +00:00
  • 3296f91bb0 Check for refusal of --delete-before when it is inferred. Wayne Davison 2005-02-15 21:15:58 +00:00
  • e2124620eb Moved two paragraphs. Wayne Davison 2005-02-15 20:42:36 +00:00
  • 69864a5ccf Made showchg() use safe_fname(). Wayne Davison 2005-02-15 20:41:37 +00:00
  • 5b4e1f318d - Mention the addition of --itemize-changes. - Mention the setting of read_only when a daemon is read-only. Wayne Davison 2005-02-15 19:47:57 +00:00
  • b78296cb0b Decided on a better option name --itemize-changes (-i). Wayne Davison 2005-02-15 07:41:13 +00:00
  • 06a1dbad61 Implemented the --what-has-changed functionality. Wayne Davison 2005-02-15 07:20:14 +00:00
  • 93c31c1a6d Don't force -v with -n if -w was specified. Wayne Davison 2005-02-15 07:20:11 +00:00
  • a8ed495833 If -w and -v are both on, don't output the "log the transfer" verbose message. Wayne Davison 2005-02-15 07:20:04 +00:00
  • 4a14ed068c Added --what-has-changed (-w), which summaries the changes being made to the files. Wayne Davison 2005-02-15 07:20:01 +00:00
  • dc0f24976d Document --what-has-changed (-w). Wayne Davison 2005-02-15 07:19:58 +00:00
  • 1e7098b5e3 Fixed a typo. Wayne Davison 2005-02-15 03:38:04 +00:00
  • 2f24fb18c4 Make sure that there are no directory-time differences between the dirs that might trip up the check of the merged copy. Wayne Davison 2005-02-15 02:01:02 +00:00
  • 96a8ca6d98 Had a report that the __attribute__ code needs to check for __APPLE__ being defined, not APPLE. Wayne Davison 2005-02-14 22:49:51 +00:00
  • 37a5644576 One arg to matched() is supposed to be an int32. Wayne Davison 2005-02-14 22:48:28 +00:00
  • a1cbe76e2c Changed one size_t var into an int32. Wayne Davison 2005-02-14 22:47:42 +00:00
  • 98bf61c80e Improved description of --whole-file option. Wayne Davison 2005-02-14 19:09:30 +00:00
  • 01f439ec6e Fixed a mismatch in the compressed-data handling between how the sending side and the receiving side handled implicit (unsent) data. Wayne Davison 2005-02-14 08:28:00 +00:00
  • acc461c7da Changed various token variables from "int"s to "int32"s. Wayne Davison 2005-02-14 08:19:32 +00:00
  • 1585958497 The count of chunks should really be an int32, not a size_t, because that's the maximum size we can transmit over the wire. Wayne Davison 2005-02-14 08:13:47 +00:00
  • 7cacd47edd Changed the size_t variables into int32 variables. Wayne Davison 2005-02-14 08:12:22 +00:00
  • e461b9bed4 Don't let --fuzzy be used with a protocol_version < 29. Wayne Davison 2005-02-14 02:47:44 +00:00
  • 3723c04850 Mention --fuzzy. Wayne Davison 2005-02-14 02:41:35 +00:00
  • 73273075c8 Added code to read a fuzzy-basis name from the generator. Wayne Davison 2005-02-14 02:41:30 +00:00
  • 8e85be0a16 Added handling for fuzzy-basis scanning. When a fuzzy filename is chosen, the name is sent down the name-pipe to the receiver. Wayne Davison 2005-02-14 02:41:27 +00:00
  • 37802f40dc - If send_file_name() gets f set to -2, it skips the local filter rules. - Added get_dirlist(), which returns a file_list structure for the desired directory, optionally with local filter rules disabled. Wayne Davison 2005-02-14 02:41:23 +00:00
  • 06b96ffa86 Set need_name_pipe if --fuzzy was specified. Wayne Davison 2005-02-14 02:41:18 +00:00
  • c4ed1487f9 Added parsing for the --fuzzy (-y) option. Wayne Davison 2005-02-14 02:41:15 +00:00
  • e64ae6d766 Added find_filename_suffix() and fuzzy_distance(). Wayne Davison 2005-02-14 02:41:10 +00:00
  • 5b4837552b Document the --fuzzy (-y) option. Wayne Davison 2005-02-14 02:41:05 +00:00
  • d2004814f0 Changed #if to use "defined". Wayne Davison 2005-02-14 02:34:01 +00:00
  • bf0c5bec45 If f_name_cmp() discovers that two directory strings compare to an equal value without being equal pointers, substitute one of the pointers for the other in the file list. This optimizes future name comparisons. Note also that this optimization won't be triggered very often (because rsync tends to send the names grouped by dir- name at transmission time), but it's nice to be able to assume that all files in the same dir have identical dir-name pointers after the qsort is finished. Wayne Davison 2005-02-14 01:29:17 +00:00
  • 0dd046d36f Don't check defined-ness of SIZEOF_OFF64_T. Wayne Davison 2005-02-14 00:58:10 +00:00
  • 4f5b0756df John E. Malmberg convinced me to standardize on #ifs for defined values instead of non-zero. Wayne Davison 2005-02-14 00:53:43 +00:00
  • fe1c19dcdf In clean_flist(), if a duplicate is found for a dir and a non-dir, always dump the non-dir (because the dir might have contents in the list). Wayne Davison 2005-02-13 22:48:38 +00:00
  • 24b2096e86 The dir vs non-dir test now assumes the dir wins. Wayne Davison 2005-02-13 22:48:35 +00:00
  • 86e97e178d Mention the new sorting method for protocol 29. Wayne Davison 2005-02-13 22:37:29 +00:00
  • 905d906d69 Added a test for the merging of a dir and a non-dir with the same name. Wayne Davison 2005-02-13 22:01:15 +00:00
  • abce74bb93 Added some missing commas in some option summary lines. Wayne Davison 2005-02-13 21:50:55 +00:00
  • f5db099330 - Made receive_file_entry() return the file_struct pointer instead of storing it into the files[] array. - Made flist_find() return "no match" if the found item differs in its directory-ness from the search item. - Changed f_name_cmp() to sort sub-directories after non-directories for each directory's contents. This makes things like the upcoming --fuzzy patch easier to get right. - One complicating factor is that clean_flist() needed some extra code to ensure that a directory doesn't duplicate a non-directory of the same name. - Make sure that the "strip_root" code in clean_flist() (for relative paths) strips off all leading slashes. Wayne Davison 2005-02-13 21:15:47 +00:00
  • 122d1771db Improved the call to f_name_cmp(). Wayne Davison 2005-02-13 20:06:18 +00:00
  • 8824e2cee4 Changed the prefix on the fnc_state enums. Wayne Davison 2005-02-13 10:23:56 +00:00
  • 8a6f3fead8 Improved the summary for the -F option. Wayne Davison 2005-02-13 05:45:42 +00:00
  • 9c71f56a25 Improved the help text for -F. Wayne Davison 2005-02-13 05:44:29 +00:00
  • f924946eba Improved the description of the --compress (-z) option. Wayne Davison 2005-02-12 22:22:14 +00:00
  • 32a5edf43f Improved the documentation of the --compress (-z) option. Wayne Davison 2005-02-12 22:21:45 +00:00
  • 9a338344da Forgot to make sure that the dir-times on the chkdir got synced in the newest test case. Wayne Davison 2005-02-12 21:22:21 +00:00
  • df337831dc When --dry-run is set, note when a directory is missing and avoid trying to stat() any items inside that dir's hierarchy. This fixes a bug where a symlink to a dir getting replaced by a dir with identical contents to the dir at the other end of the symlink would not report the updated files in the new hierarchy. (See bug #1673) Wayne Davison 2005-02-12 21:18:58 +00:00
  • bb558f6791 Some more improvements to exercise rule-restricted merge files (i.e. exclude patterns only) and side-restricted filter rules. Wayne Davison 2005-02-12 20:45:39 +00:00
  • 22558cdd7e Improved checkit() and rsync_ls_lR() to work with filenames that might have spaces. Wayne Davison 2005-02-12 20:25:12 +00:00
  • 28c54e81c1 Mention the protocol change for --delete-excluded. Wayne Davison 2005-02-12 19:52:40 +00:00
  • 0dfffb88e1 Document the new filter rule flags for sender-/receiver-specific rules. Wayne Davison 2005-02-12 19:52:34 +00:00
  • ed243f8c29 - Added modifiers for the include/exclude rules that makes them apply to the indicated (sender/receiver) side. - Added the hide/show and protect/risk filter rules as an alternate way to specify sender-/receiver-specific include/exclude rules. - send_rules() now allows f_out to be -1 to indicate that the list should be scanned but not sent. - send_rules() now filters the list to remove any items that don't apply to the current side (after sending the item to the other side when f_out != -1). - {send,recv}_filter_list() now transfer the list, even when the receiver is the server and --delete-excluded was specified (the exchanged list is appropriately filtered, of course). - recv_filter_list() uses send_rules() to trim non-applicable rules when we're a local-server (because we got our filter list without send/recv calls when fork() duplicated it). Wayne Davison 2005-02-12 19:52:26 +00:00
  • a427e8938a - Define MATCHFLG_SENDER_SIDE and MATCHFLG_RECEIVER_SIDE. - Updated MATCHFLGS_FROM_CONTAINER. Wayne Davison 2005-02-12 19:52:22 +00:00
  • cc25d29132 We don't need to avoid the local filter list in send_file_name() when --delete-excluded is set because our list has been trimmed to only include rules that apply in the current mode. Wayne Davison 2005-02-12 19:52:18 +00:00
  • 134f43385b - Since send_file_list() is no longer called with f == -1, got rid of all the conditional code to support that. - Improved the comment before send_directory() to indicate that it gets called with f == -1 from delete_in_dir(). Wayne Davison 2005-02-12 18:40:15 +00:00
  • a5a264842e Don't use underscores in the example filter rules. Wayne Davison 2005-02-11 23:16:41 +00:00
  • eed47b6b9c Made "i" a size_t in receive_sums(). Wayne Davison 2005-02-11 20:46:55 +00:00
  • 3841a04e88 A minor tweak for the dry_run logic. Wayne Davison 2005-02-11 20:26:08 +00:00
  • 9eef8f0b73 Improved the "refuse options" section, including an update to the section that talked about --del being a popt alias (which is no longer true). Wayne Davison 2005-02-11 10:52:50 +00:00
  • c258230722 - Several improvements in describing how options imply other options. - Improved --partial-dir. Wayne Davison 2005-02-11 10:51:25 +00:00
  • 345e0988cb Changed rule_match() to rule_strcmp(). Likewise for the define RULE_MATCH() being changed into RULE_STRCMP(). Wayne Davison 2005-02-11 10:47:43 +00:00
  • 3671987f4d - Added some new refused_* variables that note if certain options have been refused on the server daemon. This allows us to reject implied options (e.g. if --partial is refused and -P specified). - Changed the handling of the --delete refusals from the old idiom of upgrading "delete" to "delete*" into the new idiom of checking if refused_delete is set when we determine --delete was implied. - Changed the --del option from a popt alias into a normal option. - Mark all the daemon options as refused when a daemon is parsing the over-the-socket options. - Created a new function, create_refuse_error(), which is now called from all the spots that check for refused options. - Don't call clean_fname() on an empty string -- either reject it or handle it without erroneously expanding the string. - If --delay-updates was specified without a --partial-dir option, don't send the default "--partial-dir=.~tmp~" option if the server is the receiver -- just let it default. Wayne Davison 2005-02-11 10:42:55 +00:00
  • 5aa7b20a3e Have partial_dir_fname() also check if the dir is excluded by the server, not just the partial file. Wayne Davison 2005-02-11 09:58:31 +00:00
  • 68795c640b If a --delay-update can't use the partial-dir (e.g. if a server daemon excludes the dir or file), update the file without delay. Wayne Davison 2005-02-11 09:56:28 +00:00
  • 4f1f94d1de Improved the --modify-window description. Wayne Davison 2005-02-09 17:08:23 +00:00