using perl/cgi to access remote Haskell compiler.

Discussion in 'Perl Misc' started by zeus.zamani@gmail.com, Mar 15, 2005.

  1. Guest

    Hi all,

    Completely stuck on this one, so any suggestions/tips would be great.


    When I run the following shell command through perl I get the desired
    output:

    system("hugs filename.hs");

    This brings up the haskell compiler and compiles the hs file.

    If this were to be done directly in shell after the command, the prompt
    would change to Main> indicating that its within the hugs environment.

    At this point I dont know how to instruct perl to give an argument to
    the program. I looked at pipelining commands, but seems to be that only
    works for actual shell commands and not when you're 'inside of a
    program'.

    Any adivse on this would be greatly appreciated.

    Thanks guys..

    Zeus
     
    , Mar 15, 2005
    #1
    1. Advertisements

  2. <> wrote:


    > system("hugs filename.hs");
    >
    > This brings up the haskell compiler and compiles the hs file.
    >
    > If this were to be done directly in shell after the command, the prompt
    > would change to Main> indicating that its within the hugs environment.
    >
    > At this point I dont know how to instruct perl to give an argument to
    > the program.



    I think you need:

    perldoc -q expect

    How can I write expect in Perl?


    --
    Tad McClellan SGML consulting
    Perl programming
    Fort Worth, Texas
     
    Tad McClellan, Mar 15, 2005
    #2
    1. Advertisements

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. praba kar

    Python-cgi or Perl-cgi script doubt

    praba kar, Jul 30, 2005, in forum: Python
    Replies:
    1
    Views:
    1,120
    Michael Sparks
    Jul 30, 2005
  2. excord80
    Replies:
    17
    Views:
    1,119
    J Kenneth King
    Jan 29, 2009
  3. Casey Hawthorne
    Replies:
    3
    Views:
    461
  4. Alia Khouri
    Replies:
    0
    Views:
    354
    Alia Khouri
    Oct 31, 2010
  5. shumsta
    Replies:
    1
    Views:
    480
    Fabian Pilkowski
    Jul 22, 2005
  6. gavino
    Replies:
    4
    Views:
    319
    Mirco Wahab
    Jul 31, 2006
  7. Rg
    Replies:
    3
    Views:
    178
  8. kath
    Replies:
    4
    Views:
    1,126
    J. Gleixner
    Apr 9, 2007
Loading...