rsync icon indicating copy to clipboard operation
rsync copied to clipboard

Feature request: Improved help / capabillities documentation

Open richardkmichael opened this issue 5 years ago • 1 comments

I attempted to use -U (--atimes) between two local volumes (apfs and HFS) on MacOS 10.14.6, and received this error message:

rsync: This rsync does not support --atimes (-U)
rsync error: syntax or usage error (code 1) at main.c(1766) [client=3.2.3]

rsync --version reveals it indeed lacks atimes:

 $ rsync --version
rsync  version 3.2.3  protocol version 31
Copyright (C) 1996-2020 by Andrew Tridgell, Wayne Davison, and others.
Web site: https://rsync.samba.org/
Capabilities:
    64-bit files, 64-bit inums, 64-bit timestamps, 64-bit long ints,
    socketpairs, hardlinks, hardlink-specials, symlinks, IPv6, no atimes,       <======

# SNIP

It took me awhile to discover why atimes was missing. I reviewed the (Homebrew) build script which compiles rsync, the ./configure script for an atimes feature, the documentation (FAQ, etc.). I eventually discovered the NEWS.md item mentioning atimes is not supported on macOS.

It would be a time-saving feature for cross-platform users and sysadmins if rsync --version indicated why a capability or feature is unavailable. For example, disabled by configure vs. no platform support.

I skimmed options.c where the message is printed, looking at create_refuse_error and parse_one_refuse_match, and unfortunately it does not look straightforward to add "reason" information to a lack of a particular option. So I understand this feature might be impractical. Just adding a thought here in case there are ever improvements to the opt parsing code.

Thank you!

richardkmichael avatar Nov 12 '20 16:11 richardkmichael

For completeness, --atimes will be supported on macOS in 3.2.4 version.

Added support for --atimes on macOS and fixed a bug where it wouldn't work without --times.

juanmirocks avatar Mar 27 '22 12:03 juanmirocks