![]() |
Hello and Welcome from United States to the UNIX and Linux Forums! Thank You for Visiting and Joining Our Global Community.
|
|
google unix.com
|
|||||||
| Forums | Register | Forum Rules | Links | Albums | FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
| Shell Programming and Scripting Post questions about KSH, CSH, SH, BASH, PERL, PHP, SED, AWK and OTHER shell scripts and shell scripting languages here. |
More UNIX and Linux Forum Topics You Might Find Helpful
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| how to stop to current directory using find | james_falco | UNIX for Dummies Questions & Answers | 1 | 07-17-2007 09:43 PM |
| how do i exclude the current directory when using find? | mjays | Shell Programming and Scripting | 7 | 04-24-2007 09:13 AM |
| Question about Restricting Search path of FIND to current directory | super_duper_guy | UNIX for Dummies Questions & Answers | 2 | 10-17-2005 10:10 AM |
| find directory not including current | dangral | UNIX for Dummies Questions & Answers | 2 | 01-26-2005 03:02 PM |
| using find command only in current directory | jliebling | UNIX for Dummies Questions & Answers | 5 | 02-22-2001 10:00 PM |
![]() |
|
|
LinkBack | Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
|
|
||||
|
Find files ONLY in current directory
Hello all,
I am having a hard type in figuring out how to only gather certain files in the current directory without exploring its subdirectories. I tried: find . -name "*.ksh" -prune this also returns ksh files from lower subdirectories. I also tried find . -ls -name "*.ksh" This also returned files in lower subdirs. Can you help me, please. Thanks. |
|
||||
|
Quote:
Code:
ls *.ksh |
|
||||
|
My question is all driven by this:
I am interested in files in my current directory, such files have either a ksh extension or no extension at all. I want to gather these files through a one line command and follow this with a grep to go through this list and produce a second list of the ones which have a particular string in them Final result I found my search string in either ksh files or no extension files. Can you help? Thanks. |
![]() |
| Bookmarks |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|