At 10:54 PM -0500 1/4/02, David Miller wrote:
>What I usually want to do is something more like ls *.out |wc -l,
>or grep something *.data or cat *.foo | grep something.
>
>I have rebuilt the system in the past after greatly expanding
>ARG_MAX, and that does what I want. I'm just looking for an e
Sorry for replying to myself, but this just came to my
mind ...
Oliver Fromme <[EMAIL PROTECTED]> wrote:
> David Miller <[EMAIL PROTECTED]> wrote:
> > What I usually want to do is something more like ls *.out |wc -l
>
> ls | grep '\.out$' | wc -l
A smaller solution would be:
echo *.out | w
Leo Bicknell <[EMAIL PROTECTED]> wrote:
> In a message written on Sat, Jan 05, 2002 at 09:48:40PM +0100, Oliver Fromme wro
> te:
> > ls | grep '\.out$' | wc -l
>
> One process shorter: find -name "*.out" -maxdepth 0 | wc -l
OK, but I tried to be as portable as possible, while
-maxdepth is n
Ok, there are several issues here that I just have to point out. :-)
In a message written on Sat, Jan 05, 2002 at 09:48:40PM +0100, Oliver Fromme wrote:
> ls | grep '\.out$' | wc -l
One process shorter: find -name "*.out" -maxdepth 0 | wc -l
> ls | grep '\.data$' | xargs grep something
Two pr
David Miller <[EMAIL PROTECTED]> wrote:
> What I usually want to do is something more like ls *.out |wc -l
ls | grep '\.out$' | wc -l
> or grep something *.data
ls | grep '\.data$' | xargs grep something
> or cat *.foo | grep something.
ls | grep '\.foo$' | xargs cat | grep something
In g
David Miller wrote:
> > Probably, you are doing something whic you aren't telling us,
> > like saying "ls *.c | wc -l" or otherwise using globbing that
> > the shell expands to too large a list.
> >
> > The easy answer is "use ``find'' instead of ``ls''".
>
> Indeed, but it doesn't answer the bas
On Fri, Jan 04, 2002 at 07:53:52PM -0800, Terry Lambert wrote:
> Brooks Davis wrote:
> > > I have a system where I need/want to handle lots of files in a single
> > > directory. Lots as in 100-200K files. ls | wc -l breaks because the
> > > value of ARG_MAX in sys/syslimits.h is too small. If I
On Fri, 4 Jan 2002, Terry Lambert wrote:
> David Miller wrote:
> > Apologies if this belongs on -questions. I couldn't find what I needed in
> > the archives or handbook.
> >
> > I have a system where I need/want to handle lots of files in a single
> > directory. Lots as in 100-200K files. ls
Brooks Davis wrote:
> > I have a system where I need/want to handle lots of files in a single
> > directory. Lots as in 100-200K files. ls | wc -l breaks because the
> > value of ARG_MAX in sys/syslimits.h is too small. If I change it from
> > 65536 to 4meg and rebuild the world it works fine.
David Miller wrote:
> Apologies if this belongs on -questions. I couldn't find what I needed in
> the archives or handbook.
>
> I have a system where I need/want to handle lots of files in a single
> directory. Lots as in 100-200K files. ls | wc -l breaks because the
> value of ARG_MAX in sys/
On Fri, Jan 04, 2002 at 09:50:45PM -0500, David Miller wrote:
> Apologies if this belongs on -questions. I couldn't find what I needed in
> the archives or handbook.
It almost certaintly did.
> I have a system where I need/want to handle lots of files in a single
> directory. Lots as in 100-20
11 matches
Mail list logo