Ok this is the easiest way to retrieve Location and Mapset in a Script right?<div>And I can use it in a If sentence without any problems?<br><br><div class="gmail_quote">On Wed, Feb 3, 2010 at 5:39 PM, Glynn Clements <span dir="ltr">&lt;<a href="mailto:glynn@gclements.plus.com">glynn@gclements.plus.com</a>&gt;</span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;"><div><div></div><div class="h5"><br>
Pedro Roma wrote:<br>
<br>
&gt; I&#39;m developing a few scripts but a few r.mapcalc lines will depend on the<br>
&gt; location and mapset. I mean, I will have different factors for different<br>
&gt; Locations and mapsets.<br>
&gt; Is there any variables with location names and mapsets?<br>
&gt; And is it possibvle to use in if setences in GRASS Bash scripts or even in<br>
&gt; PERL Scripts? (I suppose So)<br>
<br>
</div></div>You can query GRASS variables using g.gisenv. You can set shell<br>
variables with e.g.:<br>
<br>
        MAPSET=`g.gisenv get=MAPSET`<br>
<font color="#888888"><br>
--<br>
Glynn Clements &lt;<a href="mailto:glynn@gclements.plus.com">glynn@gclements.plus.com</a>&gt;<br>
</font></blockquote></div><br></div>