elisp equivalent of python shlex.split?

205 Views Asked by At

I need to parse a command line in elisp, something like:

(shlex-split "command \"Some file with spaces\" someother\ quote")
;;That gives ("command" "Some file with spaces" "someother quote")

How can I accomplish this in a simple way?

1

There are 1 best solutions below

0
On BEST ANSWER

(split-string-and-unquote "command \"Some file with spaces\" someother\ quote")