[GRASS-dev] [bug #4368] (grass) g.parser: pass through --o

Cedric Shock cedricgrass at shockfamily.net
Wed May 10 01:27:18 EDT 2006


Glynn,

> [Too much to quote]

That's some crystal clear thinking there. parser.c now does the following:

Decides to overwrite if:
a.) --o switch is present (to force for one command)
b.) If the grass variable OVERWRITE is set to 1 (to force for all commands)
c.) If the GRASS_OVERWRITE environment variable is set to 1 (so that commands 
run from scripts, system, etc. pick up on the original --o override)

When parser.c decides to overwrite it sets the GRASS_OVERWRITE environment 
variable to 1. This can be used in scripts like this one.

The OVERWRITE environment variable is no more (it never existed before my 
missed attempt).

GRASS_OVERWRITE is documented in variables.htm*

--Cedric




More information about the grass-dev mailing list