I am trying to write a tcltk script that finds the nearest site
and displays in a tk text widget stored text associated with the
site.
I want to use d.where as coordinate input to the script, but I'm
having a difficult time redirecting the stderr. It seems that
stdout is just the coordinate pairs, which I want. The stderr
includes the mouse button instructions, etc. Tcltk chokes on
the stderr, thinking that in fact there has been an error.
How do I redirect stderr to /dev/null or somewhere else. It seems
that d.where (and d.what.rast) don't understand "2>".
I get a usage error statement telling that 2 is not a valid spheroid
parameter. I would be willing to use a pipe that directed only
stderr, but don't know how to do that. I don't want to use "|&"
because then I either lose my stdout or I get the button commands,
etc. mingled in with my coordinates.
Sue Huse
REGIS
UC Berkeley