bug-bash
[Top][All Lists]
Advanced

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

Re: Option "-n" not working reliably and poorly documented


From: Jon Seymour
Subject: Re: Option "-n" not working reliably and poorly documented
Date: Thu, 12 Feb 2009 09:56:44 +1100

On Thu, Feb 12, 2009 at 8:02 AM, Paul Jarc <prj@po.cwru.edu> wrote:
> Jon Seymour <jon.seymour@gmail.com> wrote:
>> Not sure this is correct. The ] is parsed by the shell
>
> It's parsed by the [ command.  That happens to be a builtin command,
> so yes, it is done by the shell, but it is not part of the grammar of
> the shell language.
>
>> This is why the -n option reports an error, since -n suppresses
>> command execution.
>
> -n *doesn't* report an error, because it only checks that the script
> satisfies the shell grammar.  It doesn't verify that the arguments of
> builtin commands are meaningful.
>

I stand corrected.

jon.




reply via email to

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