From b80b827fde4417afc7cc28a3e45f9c472ca5824f Mon Sep 17 00:00:00 2001 From: silverpill Date: Sun, 19 Mar 2023 19:08:49 +0000 Subject: [PATCH] Document valid role names for set-role command --- CHANGELOG.md | 4 ++++ docs/mitractl.md | 2 +- mitra-cli/src/cli.rs | 1 + 3 files changed, 6 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 3fd9aca..0b1edf2 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -11,6 +11,10 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/). - Added `fep-e232` feature flag (disabled by default). - Added `account_index` parameter to Monero configuration. +### Changed + +- Documented valid role names for `set-role` command. + ### Fixed - Make webclient-to-object redirects work for remote profiles and posts. diff --git a/docs/mitractl.md b/docs/mitractl.md index e4c0b0d..a58a80b 100644 --- a/docs/mitractl.md +++ b/docs/mitractl.md @@ -38,7 +38,7 @@ Set or change password: mitractl set-password ``` -Change user's role: +Change user's role (admin, user or read_only_user). ```shell mitractl set-role diff --git a/mitra-cli/src/cli.rs b/mitra-cli/src/cli.rs index 3cbb008..7c6c50f 100644 --- a/mitra-cli/src/cli.rs +++ b/mitra-cli/src/cli.rs @@ -187,6 +187,7 @@ impl SetPassword { #[derive(Parser)] pub struct SetRole { id: Uuid, + #[clap(value_parser = ["admin", "user", "read_only_user"])] role: String, }