Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

Globbing confusion



Hi,

 I am currently writing a script to remove certain files/directories
 from my /tmp for cleanup purposes.

 Besides others I want to to match all _directories_ matching the
 patterm mc-4.6.1* but dont want to remove _files_ of that pattern.

 And I dont want any errormessage, if a certain directory/file could
 not be found.

 For that purpose I tested on the commandline the following

     cd /tmp
     ls -ld ertertert(N/)    # ertertert does not exist under /tmp

 Instead of simply getting nothing back with no "not found" I got

     drwxrwxrwt 72 root root 11776 2006-09-26 04:39 .

 In a script I would kill . in that case if "ls -ld" is replaced by
 "rm -rf" ???

 What did I wrong here ?

 Keep hacking!
 mcc



Messages sorted by: Reverse Date, Date, Thread, Author