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

Re: command -v in postinsts violating policy



Clint Adams wrote:
> I'm not sure what you mean.  A user may symlink /bin/sh to a
> POSIX-compatible shell, and install any one of those packages only to be
> faced with breakage.  That's actually broken.  Note that this shell
> may have an implementation of "command" that does not support -v or -V,
> thus not specifying an absolute path will result in failure even if a
> /bin/command exists.
> 
> It looks as though the most common culprit in these postinsts is
> something like
> 
> if [ "$1" = configure ] && command -v install-docs >/dev/null 2>&1; then
> 
> ..
> 
> If Policy isn't going to be amended, it would seem reasonable to change
> 'command -v' to 'type' in this instance.

I don't see type in posix.

-- 
see shy jo


-- 
To UNSUBSCRIBE, email to debian-devel-request@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org



Reply to: