Computer Problems? Computing.Net has over 1,000,000 posts about all things technology related! Over 90% answered within 24 hours! Click here to start participating now! Also, be sure to check out the New User Guide.
shell script HELP, output pipe...
Name: djs_wolf Date: November 22, 2004 at 09:20:45 Pacific OS: Red Hat Linux CPU/Ram: p3 laptop, 512mb ram
Comment:
I am writing a shell scrip that will run one program that will setup a FIFO output pipe and wait for another program to open it, and then open the other program on that output pipe (using it as a file input).
My question is how do you setup a script to open one program, and while that program is running open another one in a different window?
Name: Don Arnett Date: November 22, 2004 at 12:44:25 Pacific
Reply:
To start a program in another window, you should be able to run something like:
myshell "whatever command"
So if the shell you use is 'bash', then it might look like this:
/usr/bin/bash myprog
You'll want to run this in the background so that you'll get command prompt back so that you can start the first program:
/usr/bin/bash myprog &
Now you should be able to start the first program. If you have a problem because "myprog" is failing because the pipe doesn't exist yet, then start it in a script with some type of pause or sleep in it.
Be sure to come back and let us know if our suggestions helped!
0
Response Number 2
Name: 3Dave Date: November 23, 2004 at 03:29:54 Pacific
Reply:
You could probably use xterm as well, eg: $ xterm -e top &
Summary: i need help with a shell script that passes a variable. why does this not work?: echo $`echo 1` i want this to produce the same result as echo $1 but instead of the first option given at the command...
Summary: Im starting to learn bash. i lvoe it. im trying to do something but want the easy way arround. I made this script: #!/bin/bash #Author = MrJake # #Desc = will display a chmod list # # #Created on Mon ...
Summary: hi guys, i really need some help asap. Im taking an OS class and we barely skimmed over Linux. We were asked a homework question that for the life of me i have no idea how to do. the qestion is... wri...