help.c 2.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869
  1. #include "help.h"
  2. #include "../../cli_helpers.h"
  3. #include "../add/add.h"
  4. #include "../update/update.h"
  5. #include "../delete/delete.h"
  6. #include "../list/list.h"
  7. #include "../timezone/timezone.h"
  8. #include "../move/move.h"
  9. #include "../pin/pin.h"
  10. #include "../notification/notification.h"
  11. #include "../reset/reset.h"
  12. #include "../automation/automation.h"
  13. #include "../details/details.h"
  14. void totp_cli_command_help_docopt_commands() {
  15. TOTP_CLI_PRINTF(" " TOTP_CLI_COMMAND_HELP ", " TOTP_CLI_COMMAND_HELP_ALT
  16. ", " TOTP_CLI_COMMAND_HELP_ALT2 " Show command usage help\r\n");
  17. }
  18. void totp_cli_command_help_docopt_usage() {
  19. TOTP_CLI_PRINTF(" " TOTP_CLI_COMMAND_NAME " " DOCOPT_REQUIRED(
  20. TOTP_CLI_COMMAND_HELP " | " TOTP_CLI_COMMAND_HELP_ALT
  21. " | " TOTP_CLI_COMMAND_HELP_ALT2) "\r\n");
  22. }
  23. void totp_cli_command_help_handle() {
  24. TOTP_CLI_PRINTF("Usage:\r\n");
  25. totp_cli_command_help_docopt_usage();
  26. totp_cli_command_list_docopt_usage();
  27. totp_cli_command_details_docopt_usage();
  28. totp_cli_command_add_docopt_usage();
  29. totp_cli_command_update_docopt_usage();
  30. totp_cli_command_delete_docopt_usage();
  31. totp_cli_command_timezone_docopt_usage();
  32. totp_cli_command_move_docopt_usage();
  33. totp_cli_command_pin_docopt_usage();
  34. totp_cli_command_notification_docopt_usage();
  35. totp_cli_command_reset_docopt_usage();
  36. totp_cli_command_automation_docopt_usage();
  37. cli_nl();
  38. TOTP_CLI_PRINTF("Commands:\r\n");
  39. totp_cli_command_help_docopt_commands();
  40. totp_cli_command_list_docopt_commands();
  41. totp_cli_command_details_docopt_commands();
  42. totp_cli_command_add_docopt_commands();
  43. totp_cli_command_update_docopt_commands();
  44. totp_cli_command_delete_docopt_commands();
  45. totp_cli_command_timezone_docopt_commands();
  46. totp_cli_command_move_docopt_commands();
  47. totp_cli_command_pin_docopt_commands();
  48. totp_cli_command_notification_docopt_commands();
  49. totp_cli_command_reset_docopt_commands();
  50. totp_cli_command_automation_docopt_commands();
  51. cli_nl();
  52. TOTP_CLI_PRINTF("Arguments:\r\n");
  53. totp_cli_command_add_docopt_arguments();
  54. totp_cli_command_delete_docopt_arguments();
  55. totp_cli_command_move_docopt_arguments();
  56. totp_cli_command_timezone_docopt_arguments();
  57. totp_cli_command_notification_docopt_arguments();
  58. totp_cli_command_automation_docopt_arguments();
  59. cli_nl();
  60. TOTP_CLI_PRINTF("Options:\r\n");
  61. totp_cli_command_add_docopt_options();
  62. totp_cli_command_update_docopt_options();
  63. totp_cli_command_delete_docopt_options();
  64. totp_cli_command_pin_docopt_options();
  65. totp_cli_command_automation_docopt_options();
  66. }