You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

42 lines
1.4 KiB

9 years ago
9 years ago
  1. module.exports = {
  2. definitions: [
  3. {
  4. name: 'port', alias: 'p', type: Number, defaultOption: true,
  5. description: 'Web server port', group: 'server'
  6. },
  7. {
  8. name: 'log-format', alias: 'f', type: String,
  9. description: "If a format is supplied an access log is written to stdout. If not, a statistics view is displayed. Use a preset ('none', 'dev','combined', 'short', 'tiny' or 'logstalgia') or supply a custom format (e.g. ':method -> :url').", group: 'server'
  10. },
  11. {
  12. name: 'directory', alias: 'd', type: String,
  13. description: 'Root directory, defaults to the current directory', group: 'server'
  14. },
  15. {
  16. name: 'compress', alias: 'c', type: Boolean,
  17. description: 'Enable gzip compression, reduces bandwidth.', group: 'server'
  18. },
  19. {
  20. name: 'help', alias: 'h', type: Boolean,
  21. description: 'Print these usage instructions', group: 'misc'
  22. },
  23. {
  24. name: 'config', type: Boolean,
  25. description: 'Print the stored config', group: 'misc'
  26. }
  27. ],
  28. usageData: {
  29. title: 'local-web-server',
  30. description: 'Lightweight static web server, zero configuration.',
  31. footer: 'Project home: [underline]{https://github.com/75lb/local-web-server}',
  32. synopsis: [
  33. '$ ws <server options>',
  34. '$ ws --config',
  35. '$ ws --help'
  36. ],
  37. groups: {
  38. server: 'Server',
  39. misc: 'Misc'
  40. }
  41. }
  42. }