From 01e3cf7ec2b2a085d555784d04c75923ef30def8 Mon Sep 17 00:00:00 2001 From: hzmaoxunxing Date: Fri, 15 Sep 2017 16:16:34 +0800 Subject: [PATCH] @bugfix fix parsed dir when pass param like "--dir module-cps" --- src/helper/parser.coffee | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/helper/parser.coffee b/src/helper/parser.coffee index 17b0f59..66885bd 100755 --- a/src/helper/parser.coffee +++ b/src/helper/parser.coffee @@ -69,7 +69,7 @@ class Parser return char.join " " option = option.replace /\=/g," " result = [] - option.replace /--([^-][\w-]*)(\s[^\s-]+)?|-\w(\s[^\s-]+)?/g, (a) -> + option.replace /--([^-][\w-]*)(\s[^\s]+)?|-\w(\s[^\s]+)?/g, (a) -> # 第一个是flag 第二个是参数 cur = {} seps = a.split(/\s+/)