Skip to content
Browse files

README tweaks

  • Loading branch information...
1 parent fc0e505 commit d7802dc84423dfe538555b3f05b37235488a05c0 @DamonOehlman committed Aug 16, 2012
Showing with 20 additions and 0 deletions.
  1. +20 −0 README.md
View
20 README.md
@@ -54,6 +54,26 @@ These arguments are defined as per standard [nopt](https://github.com/isaacs/nop
Once defined in the `args` export, any arguments that are parsed successfully from `process.argv` will be provided as part of the `opts` object that is passed into the `run` function declared in the command handler.
+## Overriding Scaffolder Defaults
+
+When scaffolder is run (using `require('scaffolder')()`) a number of default options are passed through, but these can be overriden by providing an options object. The defaults of this options object are shown below:
+
+```js
+require('scaffolder')({
+ // an array of default command strings that will attempt to be invoked if no options are provided
+ defaultCommands: [],
+
+ // provide any default args that individual commands will incorporate / overwrite
+ defaultArgs: {},
+
+ // default nopt shorthand options
+ defaultShorthand: {},
+
+ // the path the scaffolder commands will be loaded from
+ commandPath: '', // defaults to the lib/commands folder of the project implementing scaffolder
+});
+```
+
## Scaffolder Helpers
When running an action, scaffolder provides a number of helper methods for performing common tasks.

0 comments on commit d7802dc

Please sign in to comment.
Something went wrong with that request. Please try again.