David C. Rankin wrote:
Yes, but since the expansion is handled "before" the rsync call, rsync receives the full file or directory name as needed. Look and the conditional inside the loop. rsync is only called the exact number of times needed as a result. If a directory can be passed to rsync, then it is so you eliminate any unneeded calls.
Your script still seems unnecessarily complicated to me (could be my problem): your example or calling '2nv' from your first posting: 2nv /var/log/mes* /var/log/Xorg.* /var/log/kdm.log Now, your file globbing is resolved by the shell when you call this, so you end up with something more like this: 2nv /var/log/messages [...] /var/log/Xorg.0.log [...] /var/log/kdm.log Given that, your script should not need to be more than this: #!/bin/sh SSUSER=user DESTHOST=destination DESTPATH=path rsync -ruv $@ ${SSUSER}@${DESTHOST}:${DESTPATH} I'm asusming you're achieving something else with your script, but I just can't see what it is. /Per -- Per Jessen, Zürich (11.6°C) -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org For additional commands, e-mail: opensuse+help@opensuse.org