>>>>> Glynn Clements <[EMAIL PROTECTED]> writes:

[...]

 >> It may be a stupid question, but what scripting language is proposed
 >> to replace POSIX Shell in GRASS?

 > Python.

        ACK, thanks.

 >> The GRASS environment seems to benefit a lot from relying on a
 >> Shell-like language.  E. g., I could hardly imagine using any
 >> language other than Shell for the following:

 >> $ g.mlist type=rast pattern=2008-\*-temperature \
 >>       (while read r ; do
 >>            s="$r"-celsius ; r.mapcalc "\"$s\" = \"$r\" - 273.15" ; \
 >>        done)

        Since I don't know Python, could you please show me the script
        like the above rewritten in it?

 > Interactive command-line use will continue to be through whichever
 > shell the user prefers, typically bash on Unix (maybe with the odd
 > csh user) and cmd.exe on Windows

        I wonder, how the script above could be rewritten for cmd.exe?

 > (with bash for people who prefer Unix but have to use Windows).

 > But Unix shells suck as programming languages.

        Well, perhaps.  But its orientation towards calling external
        programs (and the GRASS modules are to be external in the
        foreseeable future?) is a property which the majority of the
        programming languages (at least of the set I know) don't posess.

 > The only reason to use Bourne shell for scripts is the fact that an
 > interpreter is guaranteed to be present on every Unix system. But as
 > GRASS is no longer limited to Unix, that's no longer an advantage.

_______________________________________________
grass-dev mailing list
[email protected]
http://lists.osgeo.org/mailman/listinfo/grass-dev

Reply via email to