Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.debian.user > #200680

Re: question about ls

From Gene Heskett <gheskett@shentel.net>
Newsgroups linux.debian.user
Subject Re: question about ls
Date 2018-09-27 17:00 +0200
Message-ID <wCFVM-4ya-3@gated-at.bofh.it> (permalink)
References <wC2B3-6GE-7@gated-at.bofh.it> <wC409-7Di-7@gated-at.bofh.it> <wCDKh-3lS-5@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


On Thursday 27 September 2018 08:31:27 Greg Wooledge wrote:

> On Tue, Sep 25, 2018 at 10:27:03PM +0000, Long Wind wrote:
> > can ls show number of items in a folder?Thanks!
>
> https://mywiki.wooledge.org/BashFAQ/004

And finally, an "ls -l|wc -l" from the cli gives the answer to the 
question asked. Change the -l to -lR if there are subdirs in that 
directory. Or if you want to know how many .jpg pix, use 
"ls -l *.jpg|wc -l".  The list goes on

The wiki is educational about how to make bash dance to your tune, but 
for this I'd druther use its default behavior.

bash can be and is a very powerfull scripting language, I've ported 
nearly everything I ever wrote in ARrexx, the universal do anything 
language for the Amiga from 25 years ago, to bash, and they've worked at 
least as good as on the Amiga.

-- 
Cheers, Gene Heskett
--
"There are four boxes to be used in defense of liberty:
 soap, ballot, jury, and ammo. Please use in that order."
-Ed Howdershelt (Author)
Genes Web page <http://geneslinuxbox.net:6309/gene>

Back to linux.debian.user | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread


Thread

Scribus has stopped importing PDF files Gary Dale <garyndp@gmail.com> - 2018-09-25 23:00 +0200
  question about ls Long Wind <longwind2@yahoo.com> - 2018-09-26 00:30 +0200
    Re: question about ls Ben Caradoc-Davies <ben@transient.nz> - 2018-09-26 00:40 +0200
      Re: question about ls Long Wind <longwind2@yahoo.com> - 2018-09-26 01:00 +0200
        Re: question about ls Long Wind <longwind2@yahoo.com> - 2018-09-26 01:00 +0200
          Re: question about ls Ben Caradoc-Davies <ben@transient.nz> - 2018-09-26 01:20 +0200
            Re: question about ls Kent West <westk@acu.edu> - 2018-09-27 15:00 +0200
              Re: question about ls Greg Wooledge <wooledg@eeg.ccf.org> - 2018-09-27 15:20 +0200
                Re: question about ls Richard Hector <richard@walnut.gen.nz> - 2018-09-28 08:00 +0200
                Re: question about ls Ionel Mugurel Ciobîcă <I.M.Ciobica@gmail.com> - 2018-09-28 09:10 +0200
                Re: question about ls Greg Wooledge <wooledg@eeg.ccf.org> - 2018-09-28 14:30 +0200
                Re: question about ls Richard Hector <richard@walnut.gen.nz> - 2018-09-28 16:40 +0200
                Re: question about ls Virgo Pärna <virgo.parna@mail.ee> - 2018-10-03 14:10 +0200
                Re: question about ls Greg Wooledge <wooledg@eeg.ccf.org> - 2018-10-03 15:00 +0200
              Re: question about ls David Wright <deblis@lionunicorn.co.uk> - 2018-09-27 16:00 +0200
                Re: question about ls Greg Wooledge <wooledg@eeg.ccf.org> - 2018-09-27 16:10 +0200
                Re: question about ls David Wright <deblis@lionunicorn.co.uk> - 2018-09-27 16:30 +0200
                Re: question about ls Michael Stone <mstone@debian.org> - 2018-09-27 17:10 +0200
                Re: question about ls <tomas@tuxteam.de> - 2018-09-28 09:00 +0200
                Re: question about ls Michael Stone <mstone@debian.org> - 2018-09-28 12:50 +0200
                Re: question about ls <tomas@tuxteam.de> - 2018-09-28 09:00 +0200
    Re: question about ls Greg Wooledge <wooledg@eeg.ccf.org> - 2018-09-27 14:40 +0200
      Re: question about ls Gene Heskett <gheskett@shentel.net> - 2018-09-27 17:00 +0200
        Re: question about ls Greg Wooledge <wooledg@eeg.ccf.org> - 2018-09-27 17:10 +0200
  Re: Scribus has stopped importing PDF files rv riveravaldez <riveravaldezmail@gmail.com> - 2018-09-28 01:40 +0200

csiph-web