Welcome to the MacNN Forums.

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

You are here: MacNN Forums > Software - Troubleshooting and Discussion > Mac OS X > find cmd

find cmd
Thread Tools
har
Fresh-Faced Recruit
Join Date: Jan 2007
Status: Offline
Reply With Quote
Jan 29, 2007, 11:48 AM
 
hello,
I'm able to find file in /tmp directory and able to delete file,but its searching sub directories and also deleting.
How do i restrict find command in searching sub directories.
i mean i want to search in /tmp directory only,but not in sub-directory of /tmp/xxx..
any idea...
Thanks,
har
     
Grizzled Veteran
Join Date: Mar 2004
Status: Offline
Reply With Quote
Jan 29, 2007, 01:48 PM
 
-maxdepth 1
-HI-
     
Fresh-Faced Recruit
Join Date: Jan 2007
Status: Offline
Reply With Quote
Feb 5, 2007, 05:59 PM
 
or

ls /tmp/file

or

ls /tmp|grep -i -e "pattern"
     
   
Thread Tools
Forum Links
Forum Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On
Top
Privacy Policy
All times are GMT -5. The time now is 01:29 AM.
All contents of these forums © 1995-2011 MacNN. All rights reserved.
Branding + Design: www.gesamtbild.com
vBulletin v.3.8.7 © 2000-2011, Jelsoft Enterprises Ltd., Content Relevant URLs by vBSEO 3.3.2