DASH Shell discussions
 help / color / mirror / Atom feed
From: Herbert Xu <herbert@gondor.apana.org.au>
To: Guido Berhoerster <guido+kernel.org@berhoerster.name>
Cc: dash@vger.kernel.org
Subject: Re: test -nt/-ot behavior
Date: Mon, 22 Feb 2010 14:50:43 +0800	[thread overview]
Message-ID: <20100222065043.GA28401@gondor.apana.org.au> (raw)
In-Reply-To: <20100221122100.GA9005@wopr.local.invalid>

Guido Berhoerster <guido+kernel.org@berhoerster.name> wrote:
> 
> It should be noted that pdksh contains many other subtle
> differences and is not really compatible to either ksh88 or
> ksh93, the behavior introduced by the test builtin of earlier
> pdksh versions is likely due to a misunderstanding of ksh88's
> specified behavior which was later fixed.  So IMHO the
> consequence for ash should be to either merge the fix from pdksh
> or to drop -nt, -ot, and -ef altogether, I would prefer that
> latter since I think silently changing the behavior in an
> incompatible way is bad practice and these features are not
> specified in POSIX anyway.

Well, as you say the behaviour is not specified by POSIX so dash
isn't doing anything wrong per se.  As this has been the documented
behaviour within dash since forever I'm reluctant to change it or
for that matter, removing the feature entirely.

I think fixing scripts that rely on this for files that do not exist
would be the best option.

Cheers,
-- 
Visit Openswan at http://www.openswan.org/
Email: Herbert Xu ~{PmV>HI~} <herbert@gondor.apana.org.au>
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt

  parent reply	other threads:[~2010-02-22  6:50 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-02-21 12:21 test -nt/-ot behavior Guido Berhoerster
2010-02-21 13:10 ` Oleg Verych
2010-02-22  6:50 ` Herbert Xu [this message]
2010-02-22 10:33   ` Guido Berhoerster
2010-02-23  2:32     ` Herbert Xu

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20100222065043.GA28401@gondor.apana.org.au \
    --to=herbert@gondor.apana.org.au \
    --cc=dash@vger.kernel.org \
    --cc=guido+kernel.org@berhoerster.name \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox