ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Aaron Davies" <aaron.dav...@gmail.com>
Subject Re: Count Lines of Text?
Date Wed, 14 Jun 2006 20:13:47 GMT
On 6/14/06, Martin Gainty <mgainty@hotmail.com> wrote:

> Aaron Davies wrote:
>
> > Is there a simple way to count lines of text in a property/file? Not
> > lines of source code or anything, just raw lines of text, like "wc
> > -l". I mean, I could probably do something with line terminators, but
> > I'd rather have something that knows how to count lines properly on
> > multiple platforms.
>
> grep is your friend
> grep -c '^'  FileName

Not exactly cross-platform, is it? I might as well use "wc -l". I'm
looking for something done in ant itself.
-- 
Aaron Davies
aaron.davies@gmail.com

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@ant.apache.org
For additional commands, e-mail: user-help@ant.apache.org


Mime
View raw message