Mailing List Archive

Support open source code!


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: tlug: bash ?



--------------------------------------------------------
tlug note from "Stephen J. Turnbull" <turnbull@example.com>
--------------------------------------------------------
>>>>> "Jim" == Jim Schweizer <schweiz@example.com> writes:

    Jim> On 28-Feb-97 Stephen J. Turnbull wrote:

    >> date=$1 ls -l | grep -i "^.\43\}$date" | cut -c56-
    >>                          ^^^^^^^ What's this, gomi?

Oh, I see, you dropped the `{'; you wanted `^.\{43\}$date'.  It looked 
like modem droppings....  (I didn't realize GNU grep accepted that
kind of count; I though it was a feature of Perl that grep didn't have).

    Jim> It's supposed to grab the date starting in column 43 of the
    Jim> output of ls -l

You might actually find that find(1) is a better tool for this
purpose.

Steve

-- 
                            Stephen J. Turnbull
Institute of Policy and Planning Sciences                    Yaseppochi-Gumi
University of Tsukuba                      http://turnbull.sk.tsukuba.ac.jp/
Tel: +81 (298) 53-5091;  Fax: 55-3849              turnbull@example.com
-----------------------------------------------------------------
a word from the sponsor will appear below
-----------------------------------------------------------------
The TLUG mailing list is proudly sponsored by TWICS - Japan's First
Public-Access Internet System.  Now offering 20,000 yen/year flat
rate Internet access with no time charges.  Full line of corporate
Internet and intranet products are available.   info@example.com
Tel: 03-3351-5977   Fax: 03-3353-6096


Home | Main Index | Thread Index

Home Page Mailing List Linux and Japan TLUG Members Links