[GRASS-dev] CLI working again

I got the CLI for wxgrass working again. You can type in any command (GRASS or shell).

Non-GRASS commands will simply be passed to the shell.

GRASS commands without arguments (e.g. g.region) will open their properties dialogs for non-display commands. d.* commands without arguments will add a layer to the GUI layer tree and open their respective properties dialog (e.g., d.rast).

GRASS commands with arguments (e.g., g.region rast=elevation.10m) will be passed to the GRASS command shell for processing. d.* commands with arguments (e.g., d.rast elevation.10m) will display their results in the currently selected map display. Multiple display commands separated by commas will send overlaying graphic results to the current map display (e.g., d.rast elevation.10m,d.vect roads color=red).

Michael


Michael Barton, Professor of Anthropology
School of Human Evolution & Social Change
Center for Social Dynamics & Complexity
Arizona State University

phone: 480-965-6213
fax: 480-965-7671
www: http://www.public.asu.edu/~cmbarton

On Wednesday 06 June 2007 13:12, Michael Barton wrote:

I got the CLI for wxgrass working again. You can type in any command (GRASS
or shell).

Non-GRASS commands will simply be passed to the shell.

GRASS commands without arguments (e.g. g.region) will open their properties
dialogs for non-display commands. d.* commands without arguments will add a
layer to the GUI layer tree and open their respective properties dialog
(e.g., d.rast).

GRASS commands with arguments (e.g., g.region rast=elevation.10m) will be
passed to the GRASS command shell for processing. d.* commands with
arguments (e.g., d.rast elevation.10m) will display their results in the
currently selected map display. Multiple display commands separated by
commas will send overlaying graphic results to the current map display
(e.g., d.rast elevation.10m,d.vect roads color=red).

Michael
__________________________________________

Great news. one small nitpick: wouldn't it be better to seperate commands with
a semi-colon instead of a comma? There are some commands which use the comma
to parse multiple entries.

cheers,

--
Dylan Beaudette
Soil Resource Laboratory
http://casoilresource.lawr.ucdavis.edu/
University of California at Davis
530.754.7341

Good idea. I'll change it soon.

Michael

On 6/6/07 1:36 PM, "Dylan Beaudette" <debeaudette@ucdavis.edu> wrote:

Great news. one small nitpick: wouldn't it be better to seperate commands with
a semi-colon instead of a comma? There are some commands which use the comma
to parse multiple entries.

cheers,

__________________________________________
Michael Barton, Professor of Anthropology
School of Human Evolution & Social Change
Center for Social Dynamics and Complexity
Arizona State University

phone: 480-965-6213
fax: 480-965-7671
www: http://www.public.asu.edu/~cmbarton

I've been meaning to ask about wxgrass and CLI stuff - you're obviously working on a GUI psuedo-terminal for running commands the old-fashioned CLI way. I take it there is/will be no need for something like 'grass-xterm-wrapper', and any place that the TclTk GUI used that this pseudo terminal will work in wxgrass?

PS. did you ever get a chance to try my Terminal-enabled version of grass-xterm-wrapper? I've been lazy in committing it, so you'd have to dig it out of the email, or maybe I should just commit it anyways. It's in my binaries and I haven't heard of any problems yet...

On Jun 6, 2007, at 3:12 PM, Michael Barton wrote:

I got the CLI for wxgrass working again. You can type in any command (GRASS or shell).

Non-GRASS commands will simply be passed to the shell.

GRASS commands without arguments (e.g. g.region) will open their properties dialogs for non-display commands. d.* commands without arguments will add a layer to the GUI layer tree and open their respective properties dialog (e.g., d.rast).

GRASS commands with arguments (e.g., g.region rast=elevation.10m) will be passed to the GRASS command shell for processing. d.* commands with arguments (e.g., d.rast elevation.10m) will display their results in the currently selected map display. Multiple display commands separated by commas will send overlaying graphic results to the current map display (e.g., d.rast elevation.10m,d.vect roads color=red).

Michael

-----
William Kyngesburye <kyngchaos*at*kyngchaos*dot*com>
http://www.kyngchaos.com/

"History is an illusion caused by the passage of time, and time is an illusion caused by the passage of history."

- Hitchhiker's Guide to the Galaxy

Hi William,

On 6/8/07 7:15 AM, "William Kyngesburye" <woklist@kyngchaos.com> wrote:

I've been meaning to ask about wxgrass and CLI stuff - you're
obviously working on a GUI psuedo-terminal for running commands the
old-fashioned CLI way. I take it there is/will be no need for
something like 'grass-xterm-wrapper', and any place that the TclTk
GUI used that this pseudo terminal will work in wxgrass?

This should be unnecessary for a couple of reasons. One is that the new
wxgrass is native Mac, rather than xwindows. So stuff will run from the
regular terminal. The other is the desire to include a built in terminal
feature. This already exists in the TclTk version, but most people don't
notice or take advantage of it--probably because it's kind of on the 'busy'
side.

PS. did you ever get a chance to try my Terminal-enabled version of
grass-xterm-wrapper? I've been lazy in committing it, so you'd have
to dig it out of the email, or maybe I should just commit it
anyways. It's in my binaries and I haven't heard of any problems yet...

I guess I didn't but I'm not sure. I assumed that it was in the cvs. I've
probably buried your email somewhere. But it must be working somehow, since
I use the terminal for everything in the TclTk/x11 version of GRASS and
don't need to use the x11 terminal. I'm compiling from your *.app setup.

Michael

On Jun 6, 2007, at 3:12 PM, Michael Barton wrote:

I got the CLI for wxgrass working again. You can type in any
command (GRASS or shell).

Non-GRASS commands will simply be passed to the shell.

GRASS commands without arguments (e.g. g.region) will open their
properties dialogs for non-display commands. d.* commands without
arguments will add a layer to the GUI layer tree and open their
respective properties dialog (e.g., d.rast).

GRASS commands with arguments (e.g., g.region rast=elevation.10m)
will be passed to the GRASS command shell for processing. d.*
commands with arguments (e.g., d.rast elevation.10m) will display
their results in the currently selected map display. Multiple
display commands separated by commas will send overlaying graphic
results to the current map display (e.g., d.rast elevation.
10m,d.vect roads color=red).

Michael

-----
William Kyngesburye <kyngchaos*at*kyngchaos*dot*com>
http://www.kyngchaos.com/

"History is an illusion caused by the passage of time, and time is an
illusion caused by the passage of history."

- Hitchhiker's Guide to the Galaxy

__________________________________________
Michael Barton, Professor of Anthropology
School of Human Evolution & Social Change
Center for Social Dynamics & Complexity
Arizona State University

phone: 480-965-6213
fax: 480-965-7671
www: http://www.public.asu.edu/~cmbarton

On Jun 8, 2007, at 11:26 AM, Michael Barton wrote:

Hi William,

On 6/8/07 7:15 AM, "William Kyngesburye" <woklist@kyngchaos.com> wrote:

I've been meaning to ask about wxgrass and CLI stuff - you're
obviously working on a GUI psuedo-terminal for running commands the
old-fashioned CLI way. I take it there is/will be no need for
something like 'grass-xterm-wrapper', and any place that the TclTk
GUI used that this pseudo terminal will work in wxgrass?

This should be unnecessary for a couple of reasons. One is that the new
wxgrass is native Mac, rather than xwindows. So stuff will run from the
regular terminal. The other is the desire to include a built in terminal
feature. This already exists in the TclTk version, but most people don't
notice or take advantage of it--probably because it's kind of on the 'busy'
side.

I kinda figured it wouldn't need some sort of external pseudo-terminal thing and be able to use its own. Just checking.

PS. did you ever get a chance to try my Terminal-enabled version of
grass-xterm-wrapper? I've been lazy in committing it, so you'd have
to dig it out of the email, or maybe I should just commit it
anyways. It's in my binaries and I haven't heard of any problems yet...

I guess I didn't but I'm not sure. I assumed that it was in the cvs. I've
probably buried your email somewhere. But it must be working somehow, since
I use the terminal for everything in the TclTk/x11 version of GRASS and
don't need to use the x11 terminal. I'm compiling from your *.app setup.

So, the create location by projection values opens in a Terminal? Then yes, you must have installed it into your source. When you update your CVS you probably always get a line "M lib/init/grass-xterm-wrapper".

I'll commit it then, to make it official.

-----
William Kyngesburye <kyngchaos*at*kyngchaos*dot*com>
http://www.kyngchaos.com/

Theory of the Universe

There is a theory which states that if ever anyone discovers exactly what the universe is for and why it is here, it will instantly disappear and be replaced by something even more bizarrely inexplicable. There is another theory which states that this has already happened.

-Hitchhiker's Guide to the Galaxy 2nd season intro