I am using the older Intel based Mac so I checked my version of rsync --version which returned the 2.6.9 version.
So, I installed rsync via Homebrew and then did brew --prefix rsync which gave me the directory of /usr/local/opt/rsync. Then I found the executable at /usr/local/opt/rsync/bin/rsync.
I changed my scripts then to use that full path instead of just rsync. In your example I would then use:
/usr/local/opt/rsync/bin/rsync -avz —delete —log-file=“$LOG_FILE” “$SRC_DIR” “$DEST_DIR”
OR
/opt/homebrew/bin/rsync -avz —delete —log-file=“$LOG_FILE” “$SRC_DIR” “$DEST_DIR” if you are using Apple Silicon.
Hope this helps.
Topic:
Developer Tools & Services
SubTopic:
General
Tags: