bannaN has asked for the wisdom of the Perl Monks concerning the following question:

Hi,

Is it somehow possible to install the Term::ReadLine module from CPAN without having to press enter or type a expression?

Anyone know if or how this is possible, havent found any examples \ discussions on the topic.

Best regards

Replies are listed 'Best First'.
Re: Term::ReadLine - Automated install?
by Utilitarian (Vicar) on Jul 27, 2010 at 10:38 UTC
    I suspect an a/b question.

    Do you wish to ship a program with a dependency on Term::Readline?

    print "Good ",qw(night morning afternoon evening)[(localtime)[2]/6]," fellow monks."
      I believe he is asking about a non-interactive install, ie no prompts

        Thats right. My goal is a automated install without any prompts. Only module missing is Term::ReadLine

Re: Term::ReadLine - Automated install?
by nyamned (Sexton) on Jul 27, 2010 at 11:57 UTC
    Isn't it core module?

      It should be in the Core with 5.002 and later.

      Batch mode / Non-interactive / Scripting install may be very platform specific, especially on an older version of Perl. The OP may wish to update the post with platform and version info.

      Good luck. -c

        It should be in the Core with 5.002 and later.
        According to Module::CoreList the first stable release of Perl that included Term::Readline was 5.8.0

      well, its installed in the Bundle::CPAN bundle

Re: Term::ReadLine - Automated install?
by Khen1950fx (Canon) on Jul 28, 2010 at 06:06 UTC
    I think that you mean Term::ReadLine::Perl. From the CPAN shell, just do
    cpan> notest install Term::ReadLine::Perl
    Update:
    #!/usr/bin/perl use strict; use warnings; use CPAN; my $mod = 'Term::ReadLine::Perl'; CPAN::Shell->rematein("notest", "install", $mod);
      From the CPAN shell,

      That is interactive and can still prompt, he wants non-interactive

        You can always manually download the module and all its dependencies yourself.