flat.json 1.7 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465
  1. {
  2. "doc": {
  3. "help": "this is example flat mode",
  4. "usage": [
  5. "--help",
  6. "--version",
  7. "--ok [--verbose | --quiet] [opts...]"
  8. ]
  9. },
  10. "commands": {},
  11. "options": {
  12. "global": [
  13. {
  14. "short": "h",
  15. "long": "help",
  16. "help": "display help message"
  17. },
  18. {
  19. "short": "v",
  20. "long": "verbose",
  21. "conflicts": ["--quiet"],
  22. "help": "display verbose output"
  23. },
  24. {
  25. "short": "q",
  26. "long": "quiet",
  27. "conflicts": ["--verbose"],
  28. "help": "be silent"
  29. },
  30. {
  31. "long": "version",
  32. "conflicts": ["--help"],
  33. "help": "display CLAP version"
  34. }
  35. ],
  36. "local": [
  37. {
  38. "long": "ok",
  39. "required": true,
  40. "not_with": ["--help", "--version"]
  41. },
  42. {
  43. "short": "e",
  44. "long": "echo",
  45. "arguments": ["str"],
  46. "plural": true,
  47. "help": "print option's argument to screen"
  48. },
  49. {
  50. "short": "q",
  51. "long": "question",
  52. "requires": ["--answer"],
  53. "help": "just an option"
  54. },
  55. {
  56. "short": "a",
  57. "long": "answer",
  58. "requires": ["--question"],
  59. "help": "an answer to the question"
  60. }
  61. ]
  62. },
  63. "operands": {"no": [0]}
  64. }