help with command line deletion
Milo Velimirovic
milov at cslab.uwlax.edu
Thu Apr 19 06:25:34 PDT 2007
On Apr 19, 2007, at 7:50 AM, Ashley Aitken wrote:
> Instead of discussing the finer points of the Unix command line
> could we conjecture how / if it could have been done the Mac way?
>
> I seem to recall the Mac way for deleting such a set of files was
> to do a Finder find (or using Sherlock, now Spotlight) and then
> select all and delete.
>
> Would that have been doable in this case, given the hidden nature
> of the files, given the way Spotlight works in the Finder?
An excellent point to bring up. It is precisely because this
incarnation of the Finder & Spotlight DO NOT give the option of truly
showing ALL files and directories that we need to use shell commands
and scripts to effect the removal of invisible files. Also note that
Finder will not allow you to create a folder or rename something so
that the new name begins with a '.' - "You cannot use a name that
begins with a dot ".", because thses names are reserved for the
system. Please choose another name."
I agree with the other posters about sticking to the original UNIX
philosophy of doing one thing and doing it well (and consistently
across versions!) Once I learned the utility of find's -print0
combined with xargs' -0 it became a habit.
As for looking things up in man pages the Mac OS X way to do this is
with ManOpen and its command line counterpart openman.
Regards,
Milo
> Cheers,
> Ashley.
> PS I usually can't even remember the name of the xargs command to
> enable me to look up its man pages, and always get the find options
> wrong at least a couple of times ...
--
Milo Velimirović <milov at uwlax.edu>
Unix Computer Network Administrator 608-785-6618 Office
ITS Network Services 608-386-2817 Cell
University of Wisconsin - La Crosse
La Crosse, Wisconsin 54601 USA 43 48 48 N 91 13 53 W
--
"On two occasions, I have been asked [by members of Parliament],
'Pray, Mr. Babbage, if you put into the machine wrong figures, will
the right answers come out?' I am not able to rightly apprehend the
kind of confusion of ideas that could provoke such a question." --
Charles Babbage
More information about the MacOSX-admin
mailing list