[fgmlug] Re: Bash scripting question

  • From: chuq <chuq00@xxxxxxxxx>
  • To: fgmlug@xxxxxxxxxxxxx
  • Date: Fri, 27 Aug 2010 04:27:18 -0400

Thanks Goose, Yeah when I finish with kismet, I am also done with gpsd
and I am usually on the kismet screen when I terminate it so having
basically both end at the same time is acceptable for me.
I will try this out and report back.

Chuq
On Thu, 2010-08-26 at 16:03 -0700, Richard Zimmerman wrote:
> 
> Comments inline...
>  
> ---
> Richard "Goose" Zimmerman, ke4rit
> Mishawaka, IN
> 
> 
> 
> 
> ______________________________________________________________________
> From: chuq <chuq00@xxxxxxxxx>
> To: fgmlug@xxxxxxxxxxxxx
> Sent: Thu, August 26, 2010 3:27:10 PM
> Subject: [fgmlug] Bash scripting question
> 
> ----------------------- 
> As I am still new to programming and writing bash scripts I have a
> question for you guys to see if you can give me a hand with this..
> What I would like to accomplish is this (if any part of this is not do
> able that is fine I can make do with what won't work)
> I want to type a command such as ./start
> from there I would like for it to run a command (gpsd)
> -----------------------
> 
> 
> <start>
> #!/bin/bash
> /location/to/gpsd
> 
> 
> -----------------
> Then have it open another console tab and run a different program
> (kismet)
> ------------------
> 
> 
> Within <start>
> 
> 
> ./location/to/kismet
> *or*
> ./location/to/script2
> # spawns kismet 
> 
> 
> ----------------------
> That is the biggest part of what I want, here is the parts that may
> get tricky
> I would like to have the script stop (ctrl-c is fine) when I stop the
> second program (kismet)
> ------------------------
> 
> 
> 
> 
> When you exit kismet the original start script will end
> automatically... Are you really wanting to end gpsd instead????
> 
> 
> 
> 
> --------------------------
> And then if this is still yet possible have it run a different script
> (./done) when both of those are done.
> --------------------------
> 
> 
> 
> 
> in ./done use the killall command to kill all instances of gpsd or
> leave killall in ./start
> 
> 
> --------------------------------
> Any help on this would be appreciated..
> I have managed to write a few small scripts that help me out with
> running the programs with different variable or arguments in them, but
> I am stumped on this. The one thing that I have not been able to
> figure out is how to have bash initialize another console window.
> -----------------------------
> 
> 
> If you want another console just ./bin/bash
> 
> 
> 
> 
> -------------
> Thanks very much
> Chuq
> -------------
> 
> 
> Hopes this helps...
> 
> 
> Richard
> 
> 
> 
> 
> 
> 


** This list is PUBLICLY archived. **
PLEASE don't post personal or sensitive information unless you wish for it to 
be in the public domain. Assume that the FBI and your mother are closely 
monitoring our group. 

To visit the main website for FGMLUG go to http://www.fgmlug.org

To post to the list send email to fgmlug@xxxxxxxxxxxxxx
The archive is available at //www.freelists.org/archives/fgmlug/

You may unsubscribe or change your list settings by going to the list website 
at //www.freelists.org/list/fgmlug



Other related posts: