#! /bin/sh # This program is distributable under the terms of the GNU GPL (see # COPYING). # Test that rsync handles --*-dest correctly when the destination directory # does not exist due to --dry-run. . "$suitedir/rsync.fns" set -x fromdir="$scratchdir/from" todir="$scratchdir/to" basisdir="$scratchdir/basis" # fromdir contains both foo and bar, but basisdir contains only foo mkdir "$fromdir" mkdir "$basisdir" echo "Foo" >"$fromdir/foo" checkit "$RSYNC -avv \"$fromdir/\" \"$basisdir/\"" "$fromdir" "$basisdir" echo "Bar" >"$fromdir/bar" $RSYNC -a -n -i --compare-dest="../basis/" "$fromdir/" "$todir/" >"$scratchdir/log" diff - "$scratchdir/log" <f+++++++ bar EOF # The script would have aborted on error, so getting here means we've won. exit 0