[GRASS-user] Unix and Grass commands in Windows

Stephen Brearley mail at stephenbrearley.name
Tue Apr 23 01:58:52 PDT 2013


Hamish


Thanks for your excellent response.
Confirmed a few of my suspicions, plus some honest comment/nudges to others.
-Appreciate the hard work everybody is putting in!

  Stephen

-----Original Message-----
From: Hamish [mailto:hamish_b at yahoo.com] 
Sent: 22 April 2013 12:27
To: grass-user at lists.osgeo.org; Stephen Brearley
Subject: Re: [GRASS-user] Unix and Grass commands in Windows

Stephen wrote:
> Hi Folks  Just wondering how best to execute Unix and Grass commands 
> using Grass 6/7.0. I’m running Windows Vista,

for GRASS 6.4 it is this one:

 Start -> Programs -> GRASS GIS 6.4.3 -> GRASS GIS 6.4.3 with MSYS.


> and had
> started installing Cygwin, but this seems to be massive, and not even 
> sure if this is the best environment, as some users don’t seem happy 
> about it.

It's ok, just overkill for what you want to do. People will always be unhappy with something or other on the internet, I wouldn't let that stop you. :)  Yes, the installer is a pain.


> I had initially thought I could use the Console window, but this 
> appears not to accept Unix commands.

type "bash" at that prompt and it will. (maybe follow by " PS1='GRASS:\W> ' " to get the prompt look back)

I'm concerned that the CMD.EXE dos box console in 6.4 is still a bit half baked. The "rxvt" which runs the MSYS is not ideal either, but at least it generally works and occasionally doesn't, as opposed to the current CMD.EXE (GRASS Command Line + running
g.gui) in 6.x, which seems to me lately to be lots of things not working.  I don't use this day to day, so take with a grain of salt, maybe mine had a bad day when I tried it.

> I also tried the included MySys Unix console which appears to be a 
> Bash shell, but this does not recognise Grass commands.

there are two menu items: 

 - GRASS GIS 6.4.3 with MSYS
 - MSYS UNIX Console

the second one is just a generic UNIX prompt, the GRASS environment has not been loaded for you. the first one is what you want.


> What would you recommend is the best option if I want to use Grass 
> quite a lot, but don’t want to convert my PC to a fully fledged Linux 
> system (unless that really is the best option, such as using an 
> emulator).

I'd try the GRASS+MSys first. If that has problems, then it's pretty easy to install the free VirtualBox Virtual Machine software, then load something like xUbuntu of the OSGeo Live demo onto it. There are some step by step instructions on how to do that here: 
  http://live.osgeo.org
What I like about the Virtual Machines is that it makes the whole OS choice debate a bit moot. Set whichever one you're running to full screen, and there you are.

GRASS is still smoother on UNIX (Linux/Mac/...), but we're trying to level the playing field as fast as we can. There are still a few rough edges on Windows, but it's getting much closer.


good luck,
Hamish



More information about the grass-user mailing list