rsync invocation that is actually safe to resume
The default rsync is not safe to ctrl-C during a large file transfer. It writes in-place, so a partial file on the destination looks complete-ish but is actually truncated. This combination fixes that and also keeps the delta-transfer benefits.
rsync -aHv \
--partial --partial-dir=.rsync-partial \
--append-verify \
--info=progress2 \
--human-readable \
--exclude='.DS_Store' \
--exclude='node_modules' \
"$SRC/" "$DST/"
--partial-dir means an interrupted file lives in .rsync-partial/ on the destination, not at its final path. Next run, --append-verify picks it up and completes it, verifying the bytes already written match the source (which is what plain --append does not do and why that flag alone is dangerous).
-aHv is archive mode plus hardlinks plus verbose. --info=progress2 gives you a single ETA line across the whole transfer, which is what you actually want; --progress (the old flag) prints per-file progress and spams the terminal.
For a homelab NAS over a flaky wifi link, I wrap this in a retry loop:
until rsync -aHv --partial --partial-dir=.rsync-partial \
--append-verify --info=progress2 "$SRC/" "$DST/"; do
echo "rsync exited $?, retrying in 10s..."
sleep 10
done