diff options
author | kitsunyan | 2018-04-19 06:09:44 +0000 |
---|---|---|
committer | kitsunyan | 2018-04-19 06:09:44 +0000 |
commit | 38feb86612aa592eda7333f4cae4d868ecc13841 (patch) | |
tree | c7d77902b9c3f51e36be32275ba06e2239e24d9d /src/main.nim | |
parent | 4bcf8fc92fb7c3258befc71077af0cdf83b8431a (diff) |
Add support for abbreviated keys
Diffstat (limited to 'src/main.nim')
-rw-r--r-- | src/main.nim | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/main.nim b/src/main.nim index 467dc48..685b9d3 100644 --- a/src/main.nim +++ b/src/main.nim @@ -216,7 +216,8 @@ template withErrorHandler(propColor: Option[bool], T: typedesc, body: untyped): let init = withErrorHandler(none(bool), tuple[parsedArgs: seq[Argument], config: Config]): - let parsedArgs = splitArgs(commandLineParams(), optionsWithParameter) + let parsedArgs = splitArgs(commandLineParams(), optionsWithParameter, + (operations.map(o => o.pair.long) & allOptions.map(o => o.pair.long)).deduplicate) let pacmanConfig = obtainPacmanConfig(parsedArgs) let config = obtainConfig(pacmanConfig) (parsedArgs, config) |