LinuxQuestions.org
Review your favorite Linux distribution.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 06-15-2005, 11:59 AM   #1
louisgag
LQ Newbie
 
Registered: Feb 2005
Posts: 15

Rep: Reputation: 2
Running script in separate shell window


I am trying to run two scripts (xs and xc) from a script (xpilot.sh)

my problem is that xs is a script that does not return to the shell command prompt when done (it is a server launcher for xpilot)

therefore when I run my script, only the server starts, but not the client (xc)

I tried to add #!/bin/bash at the top of both scripts, but it doesn't help

I guess I should ask the shell to make a new shell for xs, but I couldn't figure out how. (I also tried to run the script with "sh -o ignoreeof " but I didn't work..

I'll appreciate any input,
thanks
 
Old 06-15-2005, 12:09 PM   #2
perfect_circle
Senior Member
 
Registered: Oct 2004
Location: Athens, Greece
Distribution: Slackware, arch
Posts: 1,783

Rep: Reputation: 52
When you start an application from a shell, the application is blocking the shell, and you will not get a prompt until the application exits.

In order to overcome this put an & in the end of the application, to force it to run in the background:
SO try something like :
Code:
xs &
 
Old 06-15-2005, 05:11 PM   #3
louisgag
LQ Newbie
 
Registered: Feb 2005
Posts: 15

Original Poster
Rep: Reputation: 2
Smile

thanks alot! It works just fine.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
new shell window by script or code r2d2 Programming 2 12-14-2005 01:59 PM
piping to and 'error' window from termalan (shell script) dna3e8 Linux - Software 2 03-19-2005 11:08 AM
[SHELL SCRIPT] Write at the right of the shell window Creak Linux - General 2 04-02-2004 03:00 PM
How to bring up application window to front from shell script. aleksas_m Linux - General 2 08-21-2003 01:22 PM
c/c++ running a shell script? thermalpants Programming 3 05-12-2002 11:41 AM


All times are GMT -5. The time now is 08:49 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration