From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 10150 invoked from network); 25 Oct 2005 03:09:48 -0000 Received: from news.dotsrc.org (HELO a.mx.sunsite.dk) (130.225.247.88) by ns1.primenet.com.au with SMTP; 25 Oct 2005 03:09:48 -0000 Received: (qmail 49193 invoked from network); 25 Oct 2005 03:09:40 -0000 Received: from sunsite.dk (130.225.247.90) by a.mx.sunsite.dk with SMTP; 25 Oct 2005 03:09:40 -0000 Received: (qmail 1543 invoked by alias); 25 Oct 2005 03:09:32 -0000 Mailing-List: contact zsh-users-help@sunsite.dk; run by ezmlm Precedence: bulk X-No-Archive: yes X-Seq: 9555 Received: (qmail 1533 invoked from network); 25 Oct 2005 03:09:31 -0000 Received: from news.dotsrc.org (HELO a.mx.sunsite.dk) (130.225.247.88) by sunsite.dk with SMTP; 25 Oct 2005 03:09:31 -0000 Received: (qmail 48214 invoked from network); 25 Oct 2005 03:09:30 -0000 Received: from p54851be7.dip0.t-ipconnect.de (HELO solfire) (84.133.27.231) by a.mx.sunsite.dk with SMTP; 25 Oct 2005 03:09:29 -0000 Received: from [127.0.0.1] (helo=localhost) by solfire with esmtp (Exim 4.42) id 1EUFBI-0007Ux-W5 for zsh-users@sunsite.dk; Tue, 25 Oct 2005 05:08:58 +0200 Date: Tue, 25 Oct 2005 05:08:56 +0200 (CEST) Message-Id: <20051025.050856.41172296.Meino.Cramer@gmx.de> To: zsh-users@sunsite.dk From: Meino Christian Cramer X-Mailer: Mew version 4.1 on Emacs 21.3 / Mule 5.0 (SAKAKI) Mime-Version: 1.0 X-SA-Exim-Connect-IP: 127.0.0.1 X-SA-Exim-Rcpt-To: zsh-users@sunsite.dk X-SA-Exim-Mail-From: Meino.Cramer@gmx.de Subject: Compare directories the most efficient way Content-Type: Text/Plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-SA-Exim-Version: 4.1+cvs (built Sat, 28 Aug 2004 13:10:40 +0200) X-SA-Exim-Scanned: Yes (on solfire) X-Spam-Checker-Version: SpamAssassin 3.0.4 (2005-06-05) on f.primenet.com.au X-Spam-Level: X-Spam-Status: No, score=-2.6 required=5.0 tests=AWL,BAYES_00 autolearn=ham version=3.0.4 Hi, (using Linux) I have a problem and dont know, whether zsh includes some "extras" to solve it. There are two identical directory trees with binary stuff in it but with a different prefix for example: /home/user/onetree/. and /home/user/theothertree/. Unfortunately the files in there have "invalid" filenames with spaces and other ASCII- and not-so-ASCII-traps (german Umlauts for example). It is not possible to rename the files with detox, since then other things will no longer work. I want to binary-compare all files of one tree with those corresponding ones of the other tree. For this purpose I choose the "cmp" command (but if there are others more zshy ones...I have no problem to use those.... :O). The problem is to write a function/routine/script or whatever to do that job. Everything tried result in errors like: This : file not found is : file not found one : file not found file : file not found with : file not found spaces : file not found .bz2 : file not found I tried "find -ls | cut -b 69- " as a source for escaped filenames in a for/do/done-loop but it failed the same way as mentioned above. Is there any way out? :) Thank you very much for any help in advance. Keep zshing! Meino