mirror of
https://github.com/LGUG2Z/komorebi.git
synced 2026-07-06 04:55:16 +02:00
feat(cli): add cycle-stack-index cmd
This commit adds a new komorebi command "cycle-stack-index" which allows the user to manipulate the index position of the focused window in the focused stack by swapping it with either the previous or the next window until the desired index position has been found.
This commit is contained in:
@@ -160,6 +160,7 @@ gen_enum_subcommand_args! {
|
||||
CycleMoveWorkspaceToMonitor: CycleDirection,
|
||||
Stack: OperationDirection,
|
||||
CycleStack: CycleDirection,
|
||||
CycleStackIndex: CycleDirection,
|
||||
FlipLayout: Axis,
|
||||
ChangeLayout: DefaultLayout,
|
||||
CycleLayout: CycleDirection,
|
||||
@@ -985,6 +986,9 @@ enum SubCommand {
|
||||
/// Cycle the focused stack in the specified cycle direction
|
||||
#[clap(arg_required_else_help = true)]
|
||||
CycleStack(CycleStack),
|
||||
/// Cycle the index of the focused window in the focused stack in the specified cycle direction
|
||||
#[clap(arg_required_else_help = true)]
|
||||
CycleStackIndex(CycleStackIndex),
|
||||
/// Focus the specified window index in the focused stack
|
||||
#[clap(arg_required_else_help = true)]
|
||||
FocusStackWindow(FocusStackWindow),
|
||||
@@ -2305,6 +2309,9 @@ Stop-Process -Name:komorebi -ErrorAction SilentlyContinue
|
||||
SubCommand::CycleStack(arg) => {
|
||||
send_message(&SocketMessage::CycleStack(arg.cycle_direction))?;
|
||||
}
|
||||
SubCommand::CycleStackIndex(arg) => {
|
||||
send_message(&SocketMessage::CycleStackIndex(arg.cycle_direction))?;
|
||||
}
|
||||
SubCommand::ChangeLayout(arg) => {
|
||||
send_message(&SocketMessage::ChangeLayout(arg.default_layout))?;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user