Hamish wrote: > > > The long term fix is to rewrite g.mlist not to be a hack. > > > > It's rather `g.list' that should be extended to output in > > machine-readable form. (I've already suggested the `-1' and > > `--no-decoration' options to achieve that, though I haven't > > prepared a patch as of yet.) > > right. I wonder how to deal with multiple mapsets? fully qualify > [EMAIL PROTECTED] for all map names or use a #header line with the mapset name > before each new mapset listing? Probably fully qualify everything: it's > easy enough to strip off the mapset with 's/@.*$//' or `cut -f1 [EMAIL > PROTECTED] and > much less weird to deal with.
Using header lines requires stateful parsing, which complicates matters. For machine readable output, provide an option to output either qualified or unqualified names. Qualified names should be the default, IMHO. Unqualified names are a convenience for interactive use, to save the user from having to type @mapset every time. Where map names are passed within or between programs, qualified names should always be used. -- Glynn Clements <[EMAIL PROTECTED]> _______________________________________________ grass-dev mailing list [email protected] http://lists.osgeo.org/mailman/listinfo/grass-dev
