Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR SHELL

Split a string by spaces -- preserving quoted substrings -- in Python

>>> import shlex
>>> shlex.split('this is "a test"')
['this', 'is', 'a test']
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #Split #string #spaces #preserving #quoted #substrings #Python
ADD COMMENT
Topic
Name
6+2 =