The UNIX and Linux Forums  
Hello and Welcome from United States to the UNIX and Linux Forums! Thank You for Visiting and Joining Our Global Community.

Go Back   The UNIX and Linux Forums > Top Forums > Shell Programming and Scripting
.
google unix.com




View Single Post in the UNIX and Linux Forums - Click on the Thread or Permalink to View Entire Thread -->
  #2 (permalink)  
Old 08-31-2008
Lakris Lakris is offline
Registered User
  
 

Join Date: Oct 2007
Posts: 246
I don't think it can be done, unless there is some system call to achieve that function. But You could try something like this

Code:
search='apt*'
find $(echo $PATH|tr ":" " ") -type f -name $search -perm -o+x -exec basename {} \; > searchresult.lis
unless it's too clumsy...
/Lakris

PS This won't find aliases