Solved

shell command to spawn new terminal window

Posted on 2008-10-24
1
3,291 Views
Last Modified: 2013-12-21
hi,

I need to write a shell script which gcc compiles my server / client app (server.c and client.c) and then runs them in separate terminal windows.  how can i spawn these new terminal windows?
echo 'Compiling client...'

gcc Client.c -o Client
 

echo "Compiling server..."

gcc Server.c -o Server -lpthread
 

echo "Running server..."

./Server

Open in new window

0
Comment
Question by:mstrelan
1 Comment
 
LVL 10

Accepted Solution

by:
mstrelan earned 0 total points
ID: 22801765
using gnome.terminal -x
echo 'Compiling client...'

gcc Client.c -o Client
 

echo "Compiling server..."

gcc Server.c -o Server -lpthread
 

echo "Running server..."
 

gnome-terminal -x ./Client localhost

gnome-terminal -x ./Client localhost 

./Server

Open in new window

0

Featured Post

Do You Know the 4 Main Threat Actor Types?

Do you know the main threat actor types? Most attackers fall into one of four categories, each with their own favored tactics, techniques, and procedures.

Join & Write a Comment

You ever wonder how to backup Linux system files just like Windows System Restore?  Well you can use Timeshift in Linux to perform those similar action.  This tutorial will show you how to backup your system files and keep regular intervals. Note…
Active Directory replication delay is the cause to many problems.  Here is a super easy script to force Active Directory replication to all sites with by using an elevated PowerShell command prompt, and a tool to verify your changes.
Learn several ways to interact with files and get file information from the bash shell. ls lists the contents of a directory: Using the -a flag displays hidden files: Using the -l flag formats the output in a long list: The file command gives us mor…
Get a first impression of how PRTG looks and learn how it works.   This video is a short introduction to PRTG, as an initial overview or as a quick start for new PRTG users.

707 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

14 Experts available now in Live!

Get 1:1 Help Now