Handle cligen split issue
This commit is contained in:
parent
2cec3015ed
commit
1a8e489b0f
2 changed files with 9 additions and 1 deletions
|
|
@ -1,4 +1,4 @@
|
||||||
import macros, os, sets, strformat, strutils, tables
|
import macros, os, sequtils, sets, strformat, strutils, tables
|
||||||
|
|
||||||
import regex
|
import regex
|
||||||
|
|
||||||
|
|
@ -303,3 +303,7 @@ proc getNimExpression*(expr: string): string =
|
||||||
("^", " xor "), ("&", " and "), ("|", " or "),
|
("^", " xor "), ("&", " and "), ("|", " or "),
|
||||||
("~", " not ")
|
("~", " not ")
|
||||||
])
|
])
|
||||||
|
|
||||||
|
proc getSplitComma*(joined: seq[string]): seq[string] =
|
||||||
|
for i in joined:
|
||||||
|
result = result.concat(i.split(","))
|
||||||
|
|
@ -129,6 +129,10 @@ proc main(
|
||||||
symOverride: symOverride
|
symOverride: symOverride
|
||||||
)
|
)
|
||||||
|
|
||||||
|
when defined(Windows):
|
||||||
|
# Workaround https://github.com/c-blake/cligen/issues/87
|
||||||
|
gStateRT.symOverride = gStateRT.symOverride.getSplitComma()
|
||||||
|
|
||||||
if pgrammar:
|
if pgrammar:
|
||||||
parseGrammar()
|
parseGrammar()
|
||||||
printGrammar()
|
printGrammar()
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue