Merge pull request #118 from ClementJnc/pr-dir-command-line-option
Fix #114: Overrides the nimbleDir option with value from command line
This commit is contained in:
commit
698b333421
1 changed files with 2 additions and 0 deletions
|
|
@ -74,6 +74,7 @@ Options:
|
||||||
-n, --reject Reject all interactive prompts.
|
-n, --reject Reject all interactive prompts.
|
||||||
--ver Query remote server for package version
|
--ver Query remote server for package version
|
||||||
information when searching or listing packages
|
information when searching or listing packages
|
||||||
|
--nimbledir dirname Set the Nimble directory.
|
||||||
|
|
||||||
For more information read the Github readme:
|
For more information read the Github readme:
|
||||||
https://github.com/nim-lang/nimble#readme
|
https://github.com/nim-lang/nimble#readme
|
||||||
|
|
@ -217,6 +218,7 @@ proc parseCmdLine(): Options =
|
||||||
of "accept", "y": result.forcePrompts = forcePromptYes
|
of "accept", "y": result.forcePrompts = forcePromptYes
|
||||||
of "reject", "n": result.forcePrompts = forcePromptNo
|
of "reject", "n": result.forcePrompts = forcePromptNo
|
||||||
of "ver": result.queryVersions = true
|
of "ver": result.queryVersions = true
|
||||||
|
of "nimbleDir": result.config.nimbleDir = val # overrides option from file
|
||||||
of "installed", "i": result.queryInstalled = true
|
of "installed", "i": result.queryInstalled = true
|
||||||
else: discard
|
else: discard
|
||||||
of cmdEnd: assert(false) # cannot happen
|
of cmdEnd: assert(false) # cannot happen
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue