Linux, FreeBSD, Juniper, Cisco / Network security articles and troubleshooting guides

FAQ
It is currently Mon Oct 21, 2019 4:32 am


AIX tips & tricks

Author Message
debuser
Post  Post subject: AIX 5 find -maxdepth replacement: -prune (finding without descending subdirectories)  |  Posted: Mon Mar 29, 2010 10:12 am

Joined: Thu Aug 06, 2009 2:48 am
Posts: 105

Offline
 

AIX 5 find -maxdepth replacement: -prune (finding without descending subdirectories)

Here are 3 little tips for using find under AIX to search files by specific i-node attribute, without descending into subdirectories (maxdepth 1).

1) Install find from AIX Linux toolbox

2)
Code:
find . ! -name . -prune -type f

3)
Code:
find * -prune -type f
In this case, the metacharacter star will instruct find to operate in the current directory. So you can either cd to desired dir, or
Code:
find /path/to/dest/dir/* -prune -type f





Top
Display posts from previous:  Sort by  
Print view
Who is online
Users browsing this forum: No registered users and 1 guest
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum
Jump to:  
News News Site map Site map SitemapIndex SitemapIndex RSS Feed RSS Feed Channel list Channel list


Delete all board cookies | The team | All times are UTC - 5 hours [ DST ]



phpBB SEO