help-bash
[Top][All Lists]
Advanced

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

Re: [Help-bash] getting weird output out of 'echo' w/args


From: DJ Mills
Subject: Re: [Help-bash] getting weird output out of 'echo' w/args
Date: Tue, 4 Jun 2013 11:35:09 -0400

On Thursday, May 30, 2013 11:15:20 AM Roman Rakus wrote:
  Many times I saw using tr like this:
  somecommand | tr -s [a-z] ''
  somecommand | tr -s [:space:] ' '

The brackets are also not needed in the first one, in fact they probably cause incorrect behavior as well.


On Mon, Jun 3, 2013 at 4:36 AM, Dan Douglas <address@hidden> wrote:
 
Yes. {fail,no}glob can help debugging a bit. A more useful feature would be to
fail whenever the first word of a simple command resulted from anything that
could have been interpreted as a glob, whether it matched files or not. Also
any other context where globing never ever makes sense. Other glob options are
too intrusive and are only useful when you aren't going to glob, or to toggle
temporarily.
--
Dan Douglas



What exactly are the contexts where globbing "never makes sense"? That's way too subjective, IMO. How
can you decide what "makes sense" for everyone?


reply via email to

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