Beefy Boxes and Bandwidth Generously Provided by pair Networks
go ahead... be a heretic
 
PerlMonks  

minimal shell-like interface for CLI app

by wanradt (Scribe)
on Mar 04, 2009 at 14:24 UTC ( [id://748164]=perlquestion: print w/replies, xml ) Need Help??

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

Terr, devoted!

I made little command line dictionary application, but it lacks of some shell-like functions. At least i'd like have history and line editing capabilities. And i'd like to stick to perl standard modules. Is there such tools to make it possible? If not with standard bundle, what should I look for from CPAN?

Nġnda, WK
  • Comment on minimal shell-like interface for CLI app

Replies are listed 'Best First'.
Re: minimal shell-like interface for CLI app
by Fletch (Bishop) on Mar 04, 2009 at 14:32 UTC

    Term::ReadLine is core and should satisfy your requirements, but see also this blog post (and the follow ups) implementing a repl using Moose.

    Update: Had typo'd my CPAN link there ('l' for 'L').

    The cake is a lie.
    The cake is a lie.
    The cake is a lie.

      Except Term::ReadLine is not bundled with perl base, it is what i looking for. I try for now not make too many dependencies (like Moose and namespaces), but this blog made my horizonts more wide. Thank you!

      Nġnda, WK

        Erm I screwed up my cpan link above, but CPAN, permodlib's list, and Module::CoreList all beg to differ:

        $ corelist Term::ReadLine Term::ReadLine was first released with perl 5.002

        The cake is a lie.
        The cake is a lie.
        The cake is a lie.

Re: minimal shell-like interface for CLI app
by zentara (Archbishop) on Mar 04, 2009 at 15:59 UTC

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: perlquestion [id://748164]
Approved by Corion
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others surveying the Monastery: (4)
As of 2024-04-23 16:16 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found