Skip to content

Commit

Permalink
Continue massaging CLI docs, finish the publisher part of #27
Browse files Browse the repository at this point in the history
  • Loading branch information
michaelklishin committed Dec 24, 2024
1 parent 69b07c5 commit 7ac9dfd
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/cli.rs
Original file line number Diff line number Diff line change
Expand Up @@ -241,7 +241,8 @@ pub fn parser() -> Command {
.subcommand_value_name("definitions")
.subcommands(import_subcommands()),
Command::new("publish")
.about("publish a message")
.about(color_print::cstr!("Publishes (<red>inefficiently</red>) message(s) to a queue or a stream. <bold><red>Only suitable for development and test environments</red></bold>."))
.after_long_help(color_print::cformat!("<bold>Doc guide</bold>: {}", PUBLISHER_GUIDE_URL))
.subcommand_value_name("message")
.subcommands(publish_subcommands()),
Command::new("get")
Expand Down Expand Up @@ -963,6 +964,8 @@ fn import_subcommands() -> [Command; 1] {
pub fn publish_subcommands() -> [Command; 1] {
[Command::new("message")
.about("Publishes a message to an exchange")
.about(color_print::cstr!("Publishes (<red>inefficiently</red>) message(s) to a queue or a stream. <bold><red>Only suitable for development and test environments</red></bold>. Prefer messaging or streaming protocol clients!"))
.after_long_help(color_print::cformat!("<bold>Doc guide</bold>: {}", PUBLISHER_GUIDE_URL))
.arg(
Arg::new("routing_key")
.short('k')
Expand Down
1 change: 1 addition & 0 deletions src/static_urls.rs
Original file line number Diff line number Diff line change
Expand Up @@ -38,3 +38,4 @@ pub(crate) const HTTP_API_ACCESS_PERMISSIONS_GUIDE_URL: &str =
pub(crate) const DEFINITION_GUIDE_URL: &str = "https://rabbitmq.com/docs/definitions";
pub(crate) const CONSUMER_GUIDE_URL: &str = "https://rabbitmq.com/docs/consumers";
pub(crate) const POLLING_CONSUMER_GUIDE_URL: &str = "https://rabbitmq.com/docs/consumers#polling";
pub(crate) const PUBLISHER_GUIDE_URL: &str = "https://rabbitmq.com/docs/publishers";

0 comments on commit 7ac9dfd

Please sign in to comment.