[GRASS-dev] Additional switch(es) for <g.mapsets>?
Nikos Alexandris
nik at nikosalexandris.net
Sun Feb 17 09:51:43 PST 2013
Nikos Alexandris:
> > A use case is, for example, that I need to selectively use i.landsat.toar
> > on many Mapsets (that is, on many Landsat scenes) with the default
> > method(=uncorrected) and produce At-Sensor-Reflectances while performing
> > conversion to Top-of-Atmosphere Radiance with i.landsat.toar's "-r"
> > switch.
> > Currently, in bash-scripting G7, I try first to remove access to all
> > mapsets but the current (of course) as follows:
> > # one-liner!
> > g.mapsets mapset=$(g.mapsets -p sep=newline | grep -v `g.mapset -p` | tr
> > "\n" ",") operation=remove
Martin Landa:
> If I understood well, you want something like
> g.mapsets set=<current_mapset>
> ?
I think yes!
But maybe "set" is enough? Didn't play with it much.
e.g.:
- available Mapsets: A, B , C, D, E1, E2, E3, E4
- accessible Mapsets: A, B, E1, E4
- the task is to loop over all E?s (that is, E1, E2, E3, E4) and do something
so:
- inside A
- launch loop
- enter in E1, remove all but E1 from being accessible, do something
- enter in E2 and, keep access only to E2, do something
- and so on...
thnx, Nikos
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 230 bytes
Desc: This is a digitally signed message part.
URL: <http://lists.osgeo.org/pipermail/grass-dev/attachments/20130217/f0014c5a/attachment-0001.pgp>
More information about the grass-dev
mailing list