### Table of Contents * [directoryCommand][1] * [Parameters][2] ## directoryCommand Create a commandline router with nested commands based on a directory/file structure ### Parameters * `config` **[object][3]** options object * `config.directory` **[string][4]** the directory with subdirectories and files that define the commands * `config.argv` **[array][5]** array of arguments, like process.argv.slice(2) * `config.commandName` **[string][4]** base command name of the cli tool * `config.leftColumnWidth` **integer?** width in pixels of the left column of help text * `config.rightColumnWidth` **integer?** width in pixels of the right column of help text * `config.context` **[object][3]?** context object that will be passed to every command Returns **[Promise][6]** [1]: #directorycommand [2]: #parameters [3]: https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Object [4]: https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/String [5]: https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Array [6]: https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Promise