Thread: Shell scripting
View Single Post
xstep

 
xstep's Avatar
 
Member Since: Jun 25, 2005
Location: On the road
Posts: 3,231
xstep is a name known to allxstep is a name known to allxstep is a name known to allxstep is a name known to allxstep is a name known to allxstep is a name known to allxstep is a name known to all
Mac Specs: 2011 MBP, i7, 16GB RAM, MBP 2.16Ghz Core Duo, 2GB ram, Dual 867Mhz MDD, 1.75GB ram, ATI 9800 Pro vid

xstep is offline
I'm not really sure what your looking for, but try the below sample. Don't forget to make it executable.

I named the script test.sh in my root directory, cd'd to /tmp, and typed;
~/test.sh -font 35


#!/bin/sh

echo $0 #this is the path as typed to run this script.
echo $1 $2 #there are the two variables passed in

mypwd=`pwd` #get the present working directory the user executed this from.
echo $mypwd #echo the present working directory.

exit
QUOTE Thanks