[Top][All Lists]

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

Re: Dog & cat

From: Pádraig Brady
Subject: Re: Dog & cat
Date: Wed, 04 Sep 2013 16:05:39 +0100
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:17.0) Gecko/20130110 Thunderbird/17.0.2

On 09/04/2013 10:14 AM, Pascal wrote:
> Hi,
> cat - "concatenate files and print on the standard output" - offers -s option 
> to suppress repeated empty lines.
> However, an "empty" line (visual perspective) that behave only spaces or tabs 
> is not considered as empty : one option -S that would address this scenario 
> should be added to cat...
> I hope to be clear :-)

While it's a fair suggestion, I'd be against adding this functionality to cat
as it's outside of its core functionality.

Now even `cat -s` is debatable, but at least that is also implemented in FreeBSD
and is an awkward enough operation to do in sed for example:

However a simple additional sed operation would suffice to implement -S.
Something like: sed 's/^ *$//' | cat -s

So I'd be 70:30 against implementing this.


reply via email to

[Prev in Thread] Current Thread [Next in Thread]