split out parser into its own well tested module #356
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
I've split out the parser into a stand-alone module that handles the configuration bits for us:
See: #352
You can turn on and off parsing features by using the
yargs
stanza in package.json:@nexdrew addressing your comments in yargs/yargs-parser#1,
yargs-parser
allows you to configure thecwd
which is the approach I was thinking of for loading configuration appropriately.I'd love to really dial in how the heck we handle loading configuration appropriately in the various contexts:
yargs-parser
andyargs
withnpm link
.yargs
oryargs-parser
as a dependency.-g
.We are trying to solve similar problems with loading a default version from
package.json
, I wonder if there's room for a clever module here -- I bet we can extend on some of the work Sindresorhus has done (his use-case is slightly different since he can be confident AVA is installed as a development dependency, and is run in the context of a directory, i.e., is not installed globally).Reviewers: @nexdrew, @lrlna