[GRASS-SVN] r60132 - in grass/trunk/lib/python/pygrass: docs gis

svn_grass at osgeo.org svn_grass at osgeo.org
Tue May 6 09:44:15 PDT 2014


Author: neteler
Date: 2014-05-06 09:44:15 -0700 (Tue, 06 May 2014)
New Revision: 60132

Modified:
   grass/trunk/lib/python/pygrass/docs/index.rst
   grass/trunk/lib/python/pygrass/docs/intro.rst
   grass/trunk/lib/python/pygrass/gis/__init__.py
Log:
PyGRASS sphinx manual: added gis docs; msg cosmetics

Modified: grass/trunk/lib/python/pygrass/docs/index.rst
===================================================================
--- grass/trunk/lib/python/pygrass/docs/index.rst	2014-05-06 16:22:54 UTC (rev 60131)
+++ grass/trunk/lib/python/pygrass/docs/index.rst	2014-05-06 16:44:15 UTC (rev 60132)
@@ -23,13 +23,13 @@
    :maxdepth: 2
 
    intro
+   gis
    raster
    vector
    attributes
    modules
 
 
-
 Indices and tables
 ==================
 

Modified: grass/trunk/lib/python/pygrass/docs/intro.rst
===================================================================
--- grass/trunk/lib/python/pygrass/docs/intro.rst	2014-05-06 16:22:54 UTC (rev 60131)
+++ grass/trunk/lib/python/pygrass/docs/intro.rst	2014-05-06 16:44:15 UTC (rev 60132)
@@ -1,7 +1,7 @@
 Introduction
 =============
 
-To work with ``pygrass`` you need a up-to-date version of GRASS GIS 7.
+To work with ``pygrass`` you need an up-to-date version of GRASS GIS 7.
 You can obtain a recent version following the information provided on the
 `main Web site <http://grass.osgeo.org/download/software/>`_
 of GRASS, and you can read more about compilation on the 
@@ -11,4 +11,4 @@
 GRASS GIS 7 and from the console launch ``python`` or ``ipython`` 
 (the second one is the recommended way)
 
-Read more about how to work with :doc:`raster`, :doc:`vector`, :doc:`attributes`, :doc:`modules`.
+Read more about how to work with :doc:`gis`, :doc:`raster`, :doc:`vector`, :doc:`attributes`, :doc:`modules`.

Modified: grass/trunk/lib/python/pygrass/gis/__init__.py
===================================================================
--- grass/trunk/lib/python/pygrass/gis/__init__.py	2014-05-06 16:22:54 UTC (rev 60131)
+++ grass/trunk/lib/python/pygrass/gis/__init__.py	2014-05-06 16:44:15 UTC (rev 60132)
@@ -13,7 +13,7 @@
 #from grass.script import setup
 #
 #
-#GISBASE = "/home/pietro/docdat/src/gis/grass/grass70/dist.x86_64-unknown-linux-gnu"
+#GISBASE = "/home/pietro/docdat/src/gis/grass/grass71/dist.x86_64-unknown-linux-gnu"
 #LOCATION = "nc_basic_spm_grass7'"
 #GISDBASE = "/home/pietro/docdat/gis"
 #MAPSET = "sqlite"
@@ -55,7 +55,7 @@
     elif value is '':
         return getenv(type)
     else:
-        raise GrassError("%s <%s> not found." % (type.title(),
+        raise GrassError("%s <%s> not found" % (type.title(),
                                                  join(path, value)))
 
 
@@ -70,9 +70,9 @@
 def make_mapset(mapset, location=None, gisdbase=None):
     res = libgis.G_make_mapset(gisdbase, location, mapset)
     if res == -1:
-        raise GrassError("I cannot create a new mapset.")
+        raise GrassError("Cannot create new mapset")
     elif res == -2:
-        raise GrassError("Illegal name.")
+        raise GrassError("Illegal name")
 
 
 class Gisdbase(object):
@@ -124,7 +124,7 @@
 
     def new_location(self):
         if libgis.G__make_location() != 0:
-            raise GrassError("I cannot create a new mapset.")
+            raise GrassError("Cannot create new location")
 
     def locations(self):
         """Return a list of locations that are available in the gisdbase: ::



More information about the grass-commit mailing list