From 4633b7a4d8aebbb322fee52ce9b07c26f7390626 Mon Sep 17 00:00:00 2001 From: finga Date: Tue, 22 Jun 2021 01:36:00 +0200 Subject: [PATCH] Rename `mode` clap parameter to `permissions` Rename the clap parameter when creating a new message queue `mode` to `permissions`. --- src/create.rs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/create.rs b/src/create.rs index b57ce6e..4bb17eb 100644 --- a/src/create.rs +++ b/src/create.rs @@ -7,8 +7,8 @@ use std::fs; #[derive(Clap, Debug)] pub struct Create { /// Permissions (octal) to create the queue with - #[clap(short = 'p', long)] - mode: Option, + #[clap(short, long)] + permissions: Option, /// Maximum number of messages in the queue #[clap(short, long)] capacity: Option, @@ -38,7 +38,7 @@ impl Create { pub fn run(&self, verbose: bool) -> Result<()> { let mq = &mut posixmq::OpenOptions::readonly(); - if let Some(m) = &self.mode { + if let Some(m) = &self.permissions { mq.mode(u32::from_str_radix(&m, 8)?); }