[GRASS-SVN] r60622 - grass/trunk/lib/python/script
svn_grass at osgeo.org
svn_grass at osgeo.org
Sat May 31 02:20:43 PDT 2014
Author: hcho
Date: 2014-05-31 02:20:43 -0700 (Sat, 31 May 2014)
New Revision: 60622
Modified:
grass/trunk/lib/python/script/core.py
Log:
core.py: added grass.separator() for G_OPT_F_SEP
Modified: grass/trunk/lib/python/script/core.py
===================================================================
--- grass/trunk/lib/python/script/core.py 2014-05-31 08:38:15 UTC (rev 60621)
+++ grass/trunk/lib/python/script/core.py 2014-05-31 09:20:43 UTC (rev 60622)
@@ -674,6 +674,21 @@
return _parse_opts(lines[1:])
+
+def separator(sep):
+ if sep == "pipe":
+ return "|"
+ elif sep == "comma":
+ return ","
+ elif sep == "space":
+ return " "
+ elif sep == "tab":
+ return "\t"
+ elif sep == "newline":
+ return "\n"
+ return sep
+
+
# interface to g.tempfile
More information about the grass-commit
mailing list