Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.os.linux.misc > #13566
| From | Unknown <dog@gmail.com> |
|---|---|
| Newsgroups | comp.os.linux.misc |
| Subject | Re: list but not dirs? |
| Date | 2015-02-03 11:53 +0000 |
| Organization | A noiseless patient Spider |
| Message-ID | <pan.2015.02.03.12.03.51@gmail.com> (permalink) |
| References | <pan.2015.01.27.08.20.10@gmail.com> <maat1i$ipg$1@dont-email.me> |
On Wed, 28 Jan 2015 14:51:30 +0000, Joe Beanfish wrote:
> On Tue, 27 Jan 2015 08:10:30 +0000, Unknown wrote:
>
>> This must be one of the most fundamental commands !!
>>
>> I want to see all *.pdf [or any *] in all of my 30 workSpace, with each
>> having average 3 eTerminals open.
>>
>> #!/bin/bash
>>
>> echo "List File:Arg1 inAll active Dirs:per:lsof" for Dirs in `lsof |
>> grep cwd | awk '{print $9}' | sort| uniq`; do
>> echo "In Dir: " $Dirs;
>> # if [ -f "$Dirs/*$1" ]; then ?! Can't test BEFORE listing !!
>> ls $Dirs/*$1;
>> echo "<><><><><>";
>> done -----
>> But don't list any <sub-dir>pdf
>
> "Works for me" as they say. Presumably you're running it as
> scriptname pdf
>
> By <sub-dir> do you mean $Dirs or sub directories of $Dirs?
I probably meant *$1* must be a file [not directory-name].
> To go deep
> use find instead of ls:
> find $Dirs -name "*$1" -print;
OK thanks, I'll need that too - later. Perhaps an alternative version.
How do people keep their structured-menu of such utilities?
Trying to remember is anti-computer-usage.
Back to comp.os.linux.misc | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
list but not dirs? Unknown <dog@gmail.com> - 2015-01-27 08:10 +0000
Re: list but not dirs? Tim Watts <tw_usenet@dionic.net> - 2015-01-27 09:27 +0000
Re: list but not dirs? Chris Davies <chris-usenet@roaima.co.uk> - 2015-01-27 11:56 +0000
Re: list but not dirs? Unknown <dog@gmail.com> - 2015-02-03 07:43 +0000
Re: list but not dirs? Joe Beanfish <joebeanfish@nospam.duh> - 2015-01-28 14:51 +0000
Re: list but not dirs? Unknown <dog@gmail.com> - 2015-02-03 11:53 +0000
Re: list but not dirs? Joe Beanfish <joebeanfish@nospam.duh> - 2015-02-03 14:17 +0000
Re: list but not dirs? Moe Trin <ibuprofin@painkiller.example.tld.invalid> - 2015-02-03 21:56 +0000
Re: list but not dirs? Rich <rich@example.invalid> - 2015-02-03 18:08 +0000
csiph-web