Return Styles: Pseud0ch, Terminal, Valhalla, NES, Geocities, Blue Moon. Entire thread

Do do I wrote portable shell script?

Name: Anonymous 2006-11-03 15:30

hay guyz. I am trying to write some shell scripts to automate various processes (software installation in some cases, group account creation in others) on a variety of machines at this agency I volunteer with. What they have to work with are a bunch of different unices on a variety of hardware (some run bee-estee, some run linux, some run sun) and I'm pulling my hair out trying to write scripts that work on all machines!

So, I'm wondering, which shell is better for scrypting (languages like python and pearl are not available)? So far I've been trying to make things work with the linux boxes (we have more of those) but then they bomb when I run on the other boxes (I'm calling /bin/sh not /bin/bash, btw).

So, what shell should I write to for the sake of running everywhere? bee-estee? sun? korn? Have any of you come across this problem in the workplace and did you resolve it?

Thanks for you're help guys!

Name: Anonymous 2006-11-03 15:31

Shit, that should have read "how do I", tho shell scripting sertainly resembles "do do" lol!

Name: Anonymous 2006-11-03 15:52

try ksh

Name: Anonymous 2006-11-03 16:45

put linux on all the machines

Name: Anonymous 2006-11-03 16:57 (sage)

#!/bin/sh
firefox www.opera.com

Name: Anonymous 2006-11-03 18:04

What sort of stupid question is this?

Name: Anonymous 2006-11-03 20:30

>>1
| I'm pulling my hair out trying to write scripts that work on all machines!

Bash is available on all kinds of machines, stop your whining.

| languages like python and pearl are not available

Install them if they're not available: ./configure && make install

| they bomb when I run on the other boxes

Learn the syntax, noob.

Name: Anonymous 2006-11-03 20:36

Real men write their scripts in C, use the native C compiler, and wonder why they get laid off.

Name: Anonymous 2006-11-03 20:41

Test it in dash, then you'll know it's fairly portable.

Name: Anonymous 2006-11-03 23:50

>>8
why _do_ they get laid off?

Name: Anonymous 2006-11-04 0:15

use perl you shithead. As long as you don't shell out you will be portable. You can even rename files.

Name: Anonymous 2006-11-04 5:04

>>11
clearly missed this from >>1
>(languages like python and pearl are not available)

Name: Anonymous 2006-11-04 5:18

>>12
| languages like python and pearl are not available

They would be available if you were not too lazy to INSTALL THEM!!!
./configure --prefix=$HOME && make install

Name: Anonymous 2006-11-04 5:18 (sage)

>>7
PROTIP: You quote by prefixing the line with >, not |

Name: Anonymous 2006-11-04 7:09 (sage)

>>14
Don't tell him, you fool!

Name: Anonymous 2006-11-04 9:05

>>14
|lol what?

Name: Anonymous 2006-11-04 12:35

>>1
The best way to make portable shell script is to put the script into a box and put some wheels on the box. The important parts are the wheels.

Name: Anonymous 2006-11-04 17:41

>>17
don't forget the IR remote to control it. Add flashy blinking buttons to it so it looks more 80s'.

Name: Anonymous 2010-12-17 1:38

Are you GAY?
Are you a NIGGER?
Are you a GAY NIGGER?

If you answered "Yes" to all of the above questions, then GNAA (GAY NIGGER ASSOCIATION OF AMERICA) might be exactly what you've been looking for!

Name: Anonymous 2011-02-02 23:44

Name: Anonymous 2011-02-18 13:03

check my doubles

Name: Sgt.Kabu鷘㙄kiman糵銼 2012-05-28 20:44

Bringing /prog/ back to its people
All work and no play makes Jack a dull boy
All work and no play makes Jack a dull boy
All work and no play makes Jack a dull boy
All work and no play makes Jack a dull boy
All work and no play makes Jack a dull boy
All work and no play makes Jack a dull boy
All work and no play makes Jack a dull boy
All work and no play makes Jack a dull boy
All work and no play makes Jack a dull boy
All work and no play makes Jack a dull boy
All work and no play makes Jack a dull boy
All work and no play makes Jack a dull boy
All work and no play makes Jack a dull boy
All work and no play makes Jack a dull boy
All work and no play makes Jack a dull boy
All work and no play makes Jack a dull boy
All work and no play makes Jack a dull boy
All work and no play makes Jack a dull boy
All work and no play makes Jack a dull boy
All work and no play makes Jack a dull boy
All work and no play makes Jack a dull boy
All work and no play makes Jack a dull boy
All work and no play makes Jack a dull boy
All work and no play makes Jack a dull boy
All work and no play makes Jack a dull boy
All work and no play makes Jack a dull boy
All work and no play makes Jack a dull boy

Newer Posts
Don't change these.
Name: Email:
Entire Thread Thread List