[GRASS-SVN] r69311 - grass/trunk/lib/python/pygrass/modules/interface
svn_grass at osgeo.org
svn_grass at osgeo.org
Tue Aug 30 23:50:18 PDT 2016
Author: huhabla
Date: 2016-08-30 23:50:18 -0700 (Tue, 30 Aug 2016)
New Revision: 69311
Modified:
grass/trunk/lib/python/pygrass/modules/interface/module.py
Log:
pygrass interface: Some typo fixes (merge from relbr72)
Modified: grass/trunk/lib/python/pygrass/modules/interface/module.py
===================================================================
--- grass/trunk/lib/python/pygrass/modules/interface/module.py 2016-08-31 03:34:50 UTC (rev 69310)
+++ grass/trunk/lib/python/pygrass/modules/interface/module.py 2016-08-31 06:50:18 UTC (rev 69311)
@@ -15,7 +15,6 @@
from .read import GETFROMTAG, DOC
from .env import G_debug
-
if sys.version_info[0] == 2:
from itertools import izip_longest as zip_longest
else:
@@ -372,6 +371,8 @@
Multiple run test
>>> colors = Module("r.colors", map="test_a",
... color="ryb", run_=False)
+ >>> colors.get_bash()
+ u'r.colors map=test_a color=ryb'
>>> colors.run()
Module('r.colors')
>>> colors(color="gyr")
@@ -584,11 +585,11 @@
return self
def get_bash(self):
- """Return a BASH rapresentation of the Module."""
+ """Return a BASH representation of the Module."""
return ' '.join(self.make_cmd())
def get_python(self):
- """Return a Python rapresentation of the Module."""
+ """Return a Python representation of the Module."""
prefix = self.name.split('.')[0]
name = '_'.join(self.name.split('.')[1:])
params = ', '.join([par.get_python() for par in self.params_list
More information about the grass-commit
mailing list