Advertisement
If you have a new account but are having problems posting or verifying your account, please email us on hello@boards.ie for help. Thanks :)
Hello all! Please ensure that you are posting a new thread or question in the appropriate forum. The Feedback forum is overwhelmed with questions that are having to be moved elsewhere. If you need help to verify your account contact hello@boards.ie
Hi there,
There is an issue with role permissions that is being worked on at the moment.
If you are having trouble with access or permissions on regional forums please post here to get access: https://www.boards.ie/discussion/2058365403/you-do-not-have-permission-for-that#latest

This could be an *incredibly* stupid question, but...

  • 24-05-2005 2:17pm
    #1
    Registered Users, Registered Users 2 Posts: 1,393 ✭✭✭


    I've been asked an interesting (if somewhat bizarre) question... I wouldn't have a clue, so hopefully someone can answer it for me.

    He's running a command-line program (specifically, gnuplot) on a linux box, and he wants to be able to pipe text (commands) onto the command line of that program from the shell (in this case, bash) in another window. Is this practical, or possible? Or should I just tell him to cut and paste like the rest of us?

    Cheers,
    Gadget


Comments

  • Closed Accounts Posts: 6,718 ✭✭✭SkepticOne


    What is the purpose of him wanting to do this?

    There's a program called 'expect'

    url=http://www.die.net/doc/linux/man/man1/expect.1.html]info[/url

    It is often used for automated testing of software. It will feed commands to an interactive program using a script. Can be used with standard input as well as a file. May do the job.


  • Registered Users, Registered Users 2 Posts: 1,393 ✭✭✭Inspector Gadget


    Hi:

    Thanks for the reply. I'm fully aware of expect, but it's not exactly what I want, as he wants to be able to work on the command line and pipe other stuff in (I believe this would be script-generated stuff) at irregular intervals. Thanks nonetheless.

    Cheers,
    Gadget


  • Registered Users, Registered Users 2 Posts: 354 ✭✭AndrewMc


    Hi:

    Thanks for the reply. I'm fully aware of expect, but it's not exactly what I want, as he wants to be able to work on the command line and pipe other stuff in (I believe this would be script-generated stuff) at irregular intervals. Thanks nonetheless.

    Cheers,
    Gadget

    Specifically for gnuplot, could he either
    • pipe the output of a script to a file, then use
      load "output.txt"
      
      or,
    • Run the script directly, like
      load "< script.sh"
      

    Not too familiar with it, but can't think of a generic way to do it.


Advertisement