Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 29 Mar 2005 07:19:48 +1200
From:      Jonathan Chen <jonc@chen.org.nz>
To:        Francisco Reyes <lists@natserv.com>
Cc:        freebsd-questions@freebsd.org
Subject:   Re: AWK in 4.X different from 5.X?
Message-ID:  <20050328191948.GC92392@osiris.chen.org.nz>
In-Reply-To: <20050328101610.D7970@zoraida.natserv.net>
References:  <20050326125154.Y49808@zoraida.natserv.net> <20050326142338.D50621@zoraida.natserv.net> <20050327143258.GA88210@Pandora.MHoerich.de> <20050327120743.Y26666@zoraida.natserv.net> <20050327223754.GA87442@osiris.chen.org.nz> <20050328101610.D7970@zoraida.natserv.net>

next in thread | previous in thread | raw e-mail | index | archive | help
On Mon, Mar 28, 2005 at 10:21:24AM -0500, Francisco Reyes wrote:
> On Mon, 28 Mar 2005, Jonathan Chen wrote:
> 
> >On Sun, Mar 27, 2005 at 12:09:03PM -0500, Francisco Reyes wrote:
> >>Since this was from a shell script I did
> >>date | awk '{print "#"$1 " " $2 "-" $3 "-" $6}'
> >
> >How about:
> >	date +"#%a %b - %d - %Y"
> 
> 
> Where/how do I put that?
> I tried to put it inside the awk side, but didn't work.

Eh? The command I was trying to replicate was:

    date | awk '{print "#"$1 " " $2 "-" $3 "-" $6}'

which is equivalent to :

    date +"#%a %b - %d - %Y"

Doing this within awk is another story.. Sorry.
-- 
Jonathan Chen <jonc@chen.org.nz>
----------------------------------------------------------------------
                                                          Jesus saves.
                                                       Allah forgives.
                             Cthulu thinks you'd make a nice sandwich.



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20050328191948.GC92392>