Newsgroups: comp.unix.questions Path: utzoo!utgpu!news-server.csri.toronto.edu!rpi!uupsi!rodan.acs.syr.edu!jstewart From: jstewart@rodan.acs.syr.edu (Ace Stewart) Subject: Problems with rm -f Message-ID: <1991May14.190816.17169@rodan.acs.syr.edu> Sender: jstewart@rodan.acs.syr.edu (Ace Stewart) Organization: Syracuse Univ/Eastman Kodak Co. Distribution: usa Date: Tue, 14 May 91 19:08:16 GMT System: Sun 4/490 running 4.1_PSR_A Problem: When running a "rm -f" on files that may or may not be in a sub-directory, the -f doesn't seem to suppress the error output if a file doesn't exist. Script as follows: ---------------- % ls .Mail/drafts Listing of directory 1 2 3 ,1 ,4 % rm -f .Mail/drafts/,* Remove the , files (temp files) % All okay! :) % rm -f .Mail/drafts/,* Do it again, _problems!_ No match. % ---------------- What the heck is the -f option there for if it still throws up at you if files in a sub-directory don't exist? It works fine if you are _in_ a that directory (i.e. 'rm -f ,*' run twice in the sub-directory suppresses errors correctly) Comments/suggestions/help? Am I doing something incredibly stupid? --Ace -- Ace Stewart | Affiliation: Eastman Kodak Company, Rochester, New York jstewart@rodan.acs.syr.edu jstewart@sunrise.bitnet jstewart@mothra.cns.syr.edu jstewart@sunspot.cns.syr.edu ace@suvm.bitnet rsjns@suvm.bitnet