Advertisement
mjgartendev

oclif-command-type

Apr 20th, 2019
99
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Bash 0.53 KB | None | 0 0
  1. static args = [
  2.   {
  3.     name: 'file',               // name of arg to show in help and reference with args[name]
  4.     required: false,            // make the arg required with `required: true`
  5.     description: 'output file', // help description
  6.     hidden: true,               // hide this arg from help
  7.     parse: input => 'output',   // instead of the user input, return a different value
  8.     default: 'world',           // default value if no arg input
  9.     options: ['a', 'b'],        // only allow input to be from a discrete set
  10.   }
  11. ]
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement