change the * to a .
"/scratch/temp/Departure/*" expands to
"/scratch/temp/Departure/Quattro
/scratch/temp/Departure/otherdir /scratch/temp/Departure/andanotherdir".
After removing Quattro, it's just "/scratch/temp/Departure/otherdir
/scratch/temp/Departure/andanotherdir". Only the items in the directory
are considered. Quattro isn't mentioned, and not touched. you're
saying
make everything i've got in /scratch/temp/Departure's counterpart in
Arrival just like in Departure. making it "." means make the Arrival
directory exactly like Departure. Nice addition... "*" expands only
to
non-dot files, so if you had like a ".status" or something in
Departure,
it'll propogate with ".", but not "*".
Tim Conway
conway.tim@sphlihp.com reorder name and reverse domain
303.682.4917 office, 303.921.0301 cell
Philips Semiconductor - Longmont TC
1880 Industrial Circle, Suite D
Longmont, CO 80501
Available via SameTime Connect within Philips, caesupport2 on AIM
"There are some who call me.... Tim?"
My old address <lucio@mi.iasf.cnr.it>
Sent by: rsync-admin@lists.samba.org
10/02/2002 06:07 AM
To: Rsync Mailing List <rsync@lists.samba.org>
cc: (bcc: Tim Conway/LMT/SC/PHILIPS)
Subject: deleting (empty) directories
Classification:
I am evaluating rsync for the mirroring of a website and associated
database. To exercise it and establish the correct run string I need I am
running tests LOCALLY between two test directories.
I have a /scratch/temp/Departure and a /scratch/temp/Arrival trees. I
apply changes to the Departure tree, run rsync, and do a diff -r.
Now I delete a file in Departure
rm Departure/Quattro/uno.file
rsync -vvv -rlptPzu --delete \
/scratch/temp/Departure/* /scratch/temp/Arrival/
and it does work (deletes file from Arrival/Quattro/uno.file)
Now I delete the only other file in the same directory
rm Departure/Quattro/due.file
and repeat rsync and it works too.
Now Departure/Quattro is empty so I can remove it
rmdir Departure/Quattro
and repeat rsync .... and the empty directory is NOT removed !!!
Why ?
Apparently if I do the same game one level below (e.g. with
Departure/Quattro/Sub) the empty directory Sub is instead deleted.
I am using rsync version 2.5.5 protocol version 26
Ah, using the --force option does not help. I tried that. From -vvv it
looks like that the missing "top level" directory Departure/Quattro
gets not listed at all (contrary to Departure/Quattro/Sub) and therefore
is ignored ... and Arrival/Quattro is left unchanged.
What am I doing wrong ?
----------------------------------------------------------------------------
Lucio Chiappetti - IASF/CNR - via Bassini 15 - I-20133 Milano (Italy)
----------------------------------------------------------------------------
L'Italia ripudia la guerra [...] come Italy repudiates war {...] as a
mezzo di risoluzione delle controversie way of resolution of
international
internazionali controversies
[Art. 11 Constitution of the Italian Republic]
----------------------------------------------------------------------------
For more info : http://www.mi.iasf.cnr.it/~lucio/personal.html
----------------------------------------------------------------------------
--
To unsubscribe or change options:
http://lists.samba.org/mailman/listinfo/rsync
Before posting, read: http://www.tuxedo.org/~esr/faqs/smart-questions.html