[sorry, I cc'd the wrong address... corrected.]

At 10AM +0100 on  3/11/09 you (O. STeffen BEYer) wrote:
> 2009/11/3 Ben Morrow <b...@morrow.me.uk>
> > Instead, just assume the default answer
> >
> *without* stopping, and use an environment variable to allow the user to
> > tweak the answer if they need to. You can print a message like
> >    Using the XS version since I found a compiler in /usr/bin/gcc: set
> >    PERL_DATE_CALC_NOXS=1 in the environment and re-run Makefile.PL to
> >    override this choice.
> > if you think users who might want to choose won't read the README.
> > Is there any standard environment variable for this sort of thing?
> >
> 
> Actually, there is an environment variable foreseen by MakeMaker (see
> below)!
> 
> PERL_MM_USE_DEFAULT

This is not quite what I meant. MM_USE_DEFAULT will cause prompt to take
the default action, which is fine if that is what the user wants. I am
suggesting using PERL_DATE_CALC_NOXS as a way to *change* the default
without having to answer the question.

IMHO prompt() is nearly always a mistake. (Asking question by other
means is *more* of a mistake, of course :).)

Ben

Reply via email to