aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorIvan Molodetskikh <yalterz@gmail.com>2024-05-17 11:22:52 +0400
committerIvan Molodetskikh <yalterz@gmail.com>2024-05-17 10:33:00 +0300
commit4dc7a6ceb80dfa8ac04ee9ca44a599405493f6cb (patch)
tree4732c3f3c9acc57995bfc91d6eb06a782c782141
parent36d3e70f11bde96eb67d157b22ebcdf4767af0c2 (diff)
downloadniri-4dc7a6ceb80dfa8ac04ee9ca44a599405493f6cb.tar.gz
niri-4dc7a6ceb80dfa8ac04ee9ca44a599405493f6cb.tar.bz2
niri-4dc7a6ceb80dfa8ac04ee9ca44a599405493f6cb.zip
Rearrange CLI subcommands a bit
-rw-r--r--src/cli.rs20
1 files changed, 10 insertions, 10 deletions
diff --git a/src/cli.rs b/src/cli.rs
index b6284559..24f33bc0 100644
--- a/src/cli.rs
+++ b/src/cli.rs
@@ -32,12 +32,6 @@ pub struct Cli {
#[derive(Subcommand)]
pub enum Sub {
- /// Validate the config file.
- Validate {
- /// Path to config file (default: `$XDG_CONFIG_HOME/niri/config.kdl`).
- #[arg(short, long)]
- config: Option<PathBuf>,
- },
/// Communicate with the running niri instance.
Msg {
#[command(subcommand)]
@@ -46,16 +40,22 @@ pub enum Sub {
#[arg(short, long)]
json: bool,
},
+ /// Validate the config file.
+ Validate {
+ /// Path to config file (default: `$XDG_CONFIG_HOME/niri/config.kdl`).
+ #[arg(short, long)]
+ config: Option<PathBuf>,
+ },
/// Cause a panic to check if the backtraces are good.
Panic,
}
#[derive(Subcommand)]
pub enum Msg {
- /// Print the version of the running niri instance.
- Version,
/// List connected outputs.
Outputs,
+ /// List workspaces.
+ Workspaces,
/// Print information about the focused window.
FocusedWindow,
/// Perform an action.
@@ -78,8 +78,8 @@ pub enum Msg {
#[command(subcommand)]
action: OutputAction,
},
- /// List workspaces.
- Workspaces,
+ /// Print the version of the running niri instance.
+ Version,
/// Request an error from the running niri instance.
RequestError,
}