diff --git a/display/d.vect/d.vect.html b/display/d.vect/d.vect.html index 95ebcb5caf2..4ba8494c41f 100644 --- a/display/d.vect/d.vect.html +++ b/display/d.vect/d.vect.html @@ -10,6 +10,13 @@

NOTES

which allow the user to specify vector type, colors, data fields, SQL queries, label size and justification, etc. +

When d.vect is used with where parameter on MS Windows +Command Prompt, it is important to use ˆ +carret symbol for escaping special characters < > ( ) & | , ; ". +

+d.vect map=vector_map where="cat ˆ> 10 AND cat ˆ< 20"
+
+

By default d.vect areas are filled with fill_color and outlined with color. Area outlines can be suppressed with

diff --git a/python/grass/script/utils.py b/python/grass/script/utils.py
index 4182a6eb53b..f974c4d12f3 100644
--- a/python/grass/script/utils.py
+++ b/python/grass/script/utils.py
@@ -326,13 +326,27 @@ def get_num_suffix(number, max_number):
 
 
 def split(s):
-    """!Platform specific shlex.split"""
-    if sys.version_info >= (2, 6):
-        return shlex.split(s, posix=(sys.platform != "win32"))
-    elif sys.platform == "win32":
-        return shlex.split(s.replace("\\", r"\\"))
-    else:
-        return shlex.split(s)
+    """Same shlex.split() func on all OS platforms
+
+    We don't use parameter posix=True on the OS MS Windows due to incorrectly
+    splitting command line parameters:
+
+    e.g. d.vect where="cat < 10"
+
+    is split incorrectly as follows:
+
+    'where="cat', '<', '10"'
+
+    Should be:
+
+    'where=cat < 10'
+
+
+    :param str s: cmd string
+
+    return list: cmd list
+    """
+    return shlex.split(s)
 
 
 # source: