fix(cli): tag enum arg for ws layout rule cmd

This commit ensures that the final argument of the
'workspace-layout-rule' command, which takes a variant of the
DefaultLayout enum, is properly labelled with the #[arg_enum] tag so
that serialization and deserialization works as expected with other
commands that take a DefaultLayout enum variant as an arg.

fix #171
This commit is contained in:
LGUG2Z
2022-07-03 11:05:23 -07:00
parent b982021573
commit ebcd7ce224
2 changed files with 3 additions and 2 deletions

View File

@@ -188,8 +188,8 @@ WorkspaceCustomLayout(monitor, workspace, path) {
Run, komorebic.exe workspace-custom-layout %monitor% %workspace% %path%, , Hide
}
WorkspaceLayoutRule(monitor, workspace, at_container_count, layout) {
Run, komorebic.exe workspace-layout-rule %monitor% %workspace% %at_container_count% %layout%, , Hide
WorkspaceLayoutRule(monitor, workspace, at_container_count, default_layout) {
Run, komorebic.exe workspace-layout-rule %monitor% %workspace% %at_container_count% %default_layout%, , Hide
}
WorkspaceCustomLayoutRule(monitor, workspace, at_container_count, path) {

View File

@@ -212,6 +212,7 @@ pub struct WorkspaceLayoutRule {
/// The number of window containers on-screen required to trigger this layout rule
at_container_count: usize,
#[clap(arg_enum)]
layout: DefaultLayout,
}