[GRASSLIST:3263] Wrestling with Grass5 env variables

William W. Hargrove hnw at fire.esd.ornl.gov
Thu Feb 28 16:53:28 EST 2002


Grasshoppers:

I'm a longtime grass user (since v2.0!) who has just made 5.0.0.pre3 under RH 7.2
linux.

Now I'm fooling with the environment variables.

I don't want to have to execute the grass5 script *at all*, I just want to have
access to the grass commands and the rest of the linux commands available at any
time.  This used to work great under 4.1, but I can't seem to get it to go under
5.0.0.pre3.

I have set these env variables in .bashrc:

# lines for GRASS GIS
GISBASE=/usr/local/grass5
export GISBASE
GISDBASE=/home2
export GISDBASE
GISRC=/home/hnw/.grassrc5
export GISRC
LOCATION_NAME=data
export LOCATION_NAME
MAPSET=mapsettest
export MAPSET
GIS_LOCK=
export GIS_LOCK

[hnw at broke hnw]$ pwd
/home/hnw
[hnw at broke hnw]$ cat .grassrc5
GISDBASE: /home2
LOCATION_NAME: data
MAPSET: mapsettest
GRASS_GUI: text
[hnw at broke hnw]$

But a g.list rast produces no listing, even though there are lots of rasters in
the mapsettest mapset:

[hnw at broke hnw]$ g.list rast
[hnw at broke hnw]$ g.gisenv
GISDBASE=/home2
LOCATION_NAME=data
MAPSET=mapsettest
GRASS_GUI=text
[hnw at broke hnw]$

However, everything works fine from inside the grass5 shell.

What else to I have to do to the environment to have grass commands at the regular
unix prompt?


--
William W. Hargrove                     hnw at fire.esd.ornl.gov
Environmental Sciences Division         (865) 241-2748
Oak Ridge National Laboratory           (865) 574-4665 (fax)
P.O. Box 2008, M.S. 6407                http://research.esd.ornl.gov/~hnw
Oak Ridge, TN  37830-6407               FedEx/UPS, use "Bethel Valley Rd."



More information about the grass-user mailing list