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

Re: Piuparts testing status update



Justin Pryzby <justinpryzby@users.sourceforge.net> writes:

> This is at least true for the "debconf" errors; since "debconf is a
> cache", it isn't useful to fail when the cache has already been removed.
> I guess this is why some packages use:

>    . /usr/share/debconf/confmodule || true

> They should really use 

>    f=/usr/share/debconf/confmodule
>    [ ! -e $f ] || . $f;

I assume the reason why the second is better is to avoid the error
message?  (BTW, I hope maintainers don't use the second as written rather
than the much clearer:

    if [ -e /usr/share/debconf/confmodule ] ; then
        . /usr/share/debconf/confmodule
    fi

There's no need to be obfuscated.)

-- 
Russ Allbery (rra@debian.org)               <http://www.eyrie.org/~eagle/>



Reply to: