On Sat, 09 Sep 2006 09:31:47 +0900 (JST), Tatsuya Kinoshita <[EMAIL PROTECTED]> 
said: 

> Hi, I've discovered that my adopted packages dbskkd-cdb and
> skksearch use `command -v'.

> Is `command -v' accepted for `/bin/sh' maintainer scripts?

> AFAIK, `command -v' is defined by POSIX UPE (user portability
> extension), "Debian Policy" section 10.4 says `/bin/sh' should only
> use POSIX features, "Developer's Reference" section 6.4 says it is
> "not POSIX", and several packages, such as libc6, exim4-base,
> exim4-command, bzip2, slib, gettext-doc, use it.

        I prefer the ditty of:
 if which foo >/dev/null 2>&1; then
    foo "stuff";
 fi

        /usr/bin/which belongs in debianutils, which is Essential:
 Yes, and is thus safe to use in maintainer scripts.

        manoj
-- 
Against stupidity the very gods Themselves contend in vain. Friedrich
von Schiller, "The Maid of Orleans", III, 6
Manoj Srivastava   <[EMAIL PROTECTED]>  <http://www.debian.org/%7Esrivasta/>
1024D/BF24424C print 4966 F272 D093 B493 410B  924B 21BA DABB BF24 424C


-- 
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]

Reply via email to