[ale] how do I - icon starts script starts 4 scripts

Brian MacLeod nym.bnm at gmail.com
Wed Apr 17 15:08:10 EDT 2013


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA256

On 4/17/13 2:35 PM, Ron Frazier (ALE) wrote:
> Thanks (I think) dev null.  However, sometimes it's more efficient
> to just ask someone who knows rather than spend hours searching
> through results in Google.  There are some nuances to my question
> that make the answers non obvious.


I'm going to be a grouch here.

The only nuances that aren't obvious in this situation are the
Terminal/Window Manger you use and the specification of window size,
The rest of what you asked is answered very well with the various
documents explaining how to write bash scripts, as posted by dev null,
and where you place your icon / your philosophy on how things should
start up on boot.

Unless you have ABSOLUTE physical control of this machine and its
location, I would give great pause to having the window manager
auto-login and do this unless you script in some sort of screen lock,
but that would defeat your purpose in having the terminals displaying
the information.

Frankly, if at all possible, I'd ditch the window-manager altogether
and do this in screen, but even then with your heavy concentration on
other security matters, this may not be the solution you think it is.
 And I capitalized ABSOLUTE for a reason.


BEGIN QUOTE:
- --------
So, my first question is how do I set up a basic script file with
these commands in it.  I can fill in all the details later.

cd ~/cgminer
export .....
./cgminer .....

Also, how do I put comments in the file?
- --------
END QUOTE



ummm...




BEGIN SCRIPT
- -------
#!/bin/bash

# Other than the required shell interpreter line
# above, the hashed lines are comments.
# This is a hash #

cd ~/cgminer
export .....
./cgminer .....

- -------
END SCRIPT



BEGIN QUOTE
- --------
Finally, I want to create a master script to start all the other 4.
Here's the trick.  I want the master script to start each of the sub
scripts in its own window and continue executing commands in the
master script.  I don't want the master script to hang waiting for
MINER1 to exit before executing MINER2, and so forth.

Let's say that the master script is called START-MINERS.
- --------


BEGIN START-MINERS
- --------
#!/bin/bash

# The ampersand after the command causes a fork and puts
# the job in the background.
# Commonly, geometry can be set by --geometry= option.
# See your terminal man page for details.

$TERMINAL $SCRIPT1 &
$TERMINAL $SCRIPT2 &
$TERMINAL $SCRIPT3 &
$TERMINAL $SCRIPT4 &
- --------
END START-MINERS


Brian
-----BEGIN PGP SIGNATURE-----
Version: GnuPG/MacGPG2 v2.0.18 (Darwin)
Comment: Using GnuPG with Thunderbird - http://www.enigmail.net/

iQE4BAEBCAAiBQJRbvMaGxhoa3A6Ly9rZXlzZXJ2ZXIudWJ1bnR1LmNvbQAKCRD5
XCJY/q4Y6A3iB/4lNb5bdZp2caiuz4HfBWpLPo3LrL7dyRSjwog+v/4S+o0G2Wus
XezgPtjmzyD5AfIBU6RWV7qCRqHVjNpMM4tHeyqdWhUPzTd5QXHNZI+0FBNBNqJs
aoe4K0abYUU1BnOpn3Ev5gcfflpZp72SSUWNc1LB3YvE+3JylIjG3TYYw3r3ehgy
7FreuV9xNy46G1Nq1OqGD36sqoy26bWTFElLnzQAI9mQJj5e9zLnokqm+yEyEpc1
JqhtaYmEMRE22mihTYZJb3Yig5xTPpYZdzW8z8+ipILImX3OfYqNlVIS1eYPnJN7
17AFw744XHOYFr2Bcn3QQ1lgqpGm7IcwYJfZ
=UxSn
-----END PGP SIGNATURE-----


More information about the Ale mailing list