[GRASS5] tclsh and wish

GRASS grass at geni.knu.ac.kr
Tue Dec 5 05:06:07 EST 2000


Hi developers,

I suggest to use GRASS_TCLSH and GRASS_WISH env vars to use non-standard
names. It can be easily overrided by env vars and does not require hard-coded
name. If these env vars exist, scripts use this name, otherwise standard name.

If someone uses wish8.3 instead of wish, GRASS_WISH=wish8.3 can be used.


set env vars in grass5:
-----------------------
if [ ! "$GRASS_TCLSH" ]
then
    GRASS_TCLSH=tclsh
    export GRASS_TCLSH
fi

if [ ! "$GRASS_WISH" ]
then
    GRASS_WISH=wish
    export GRASS_WISH
fi


Now scripts can have only:

wish script:
------------
#!/bin/sh
# the next line restarts using wish \
exec $GRASS_WISH "$0" "$@"


tclsh script:
-------------
#!/bin/sh
# the next line restarts using tclsh \
exec $GRASS_TCLSH "$0" "$@"


Any objections?

---------------------------------------- 
If you want to unsubscribe from GRASS Development Team mailing list write to:
minordomo at geog.uni-hannover.de with
subject 'unsubscribe grass5'



More information about the grass-dev mailing list