FAQ Search Today's Posts Mark Forums Read
» Video Reviews

» Linux Archive

Linux-archive is a website aiming to archive linux email lists and to make them easily accessible for linux users/developers.

» Sponsor

» Partners

» Sponsor

Go Back   Linux Archive > Debian > Debian User

LinkBack Thread Tools
Old 09-23-2008, 02:46 PM
Default help required for passing parameters to rsync within a script

I'm attempting to write a short script to copy all 'CONC*' files in any
subdir under ./ using rsync and filters but I can't get the correct
quoting/escaping... any ideas?

eg cmd line (all on a single line):

/home/horace/mccssmb2/src/rsync-2.6.9__icc/rsync --times --links -z
--progress --stats -v -rP --filter='+ */' --filter='+ CONC*' --filter='-
*' . michael@ratty.phy.umist.ac.uk:/data_hdd1/michael/`basename $PWD`

but I can't see how to sort FILTER in this bash script such that + and
*/ all work properly... ta, Michael

# cmd - need newer than system rsync
RSYNC_CMDS='--times --links -z --progress --stats -v --dry-run -rP'
# source top-level
SRC=. # from here down
# dest (remote)
DEST=michael@ratty.phy.umist.ac.uk:/data_hdd1/michael/`basename $PWD` #
ensure in same dir on remote

# filter: all subdirs but only CONC* files
FILTER="--filter=+ * --filter=+ CONC* --filter=- *"
echo $FILTER
set -x

To UNSUBSCRIBE, email to debian-user-REQUEST@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org

Thread Tools

All times are GMT. The time now is 09:57 PM.

VBulletin, Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO ©2007, Crawlability, Inc.
Copyright 2007 - 2008, www.linux-archive.org