-
-
Notifications
You must be signed in to change notification settings - Fork 681
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(command-panes): optionally allow panes to be closed on exit (#1869)
* feat(cli): allow option to close command pane on exit * feat(layouts): allow option to close command panes on exit * style(fmt): rustfmt
- Loading branch information
Showing
10 changed files
with
342 additions
and
22 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
60 changes: 60 additions & 0 deletions
60
..._utils__input__layout__layout_test__close_on_exit_added_to_close_on_exit_in_template.snap
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,60 @@ | ||
--- | ||
source: zellij-utils/src/input/./unit/layout_test.rs | ||
assertion_line: 1098 | ||
expression: "format!(\"{:#?}\", layout)" | ||
--- | ||
Layout { | ||
tabs: [], | ||
focused_tab_index: None, | ||
template: Some( | ||
PaneLayout { | ||
children_split_direction: Horizontal, | ||
name: None, | ||
children: [ | ||
PaneLayout { | ||
children_split_direction: Horizontal, | ||
name: None, | ||
children: [], | ||
split_size: None, | ||
run: Some( | ||
Command( | ||
RunCommand { | ||
command: "tail", | ||
args: [], | ||
cwd: None, | ||
hold_on_close: true, | ||
}, | ||
), | ||
), | ||
borderless: false, | ||
focus: None, | ||
external_children_index: None, | ||
}, | ||
PaneLayout { | ||
children_split_direction: Horizontal, | ||
name: None, | ||
children: [], | ||
split_size: None, | ||
run: Some( | ||
Command( | ||
RunCommand { | ||
command: "tail", | ||
args: [], | ||
cwd: None, | ||
hold_on_close: false, | ||
}, | ||
), | ||
), | ||
borderless: false, | ||
focus: None, | ||
external_children_index: None, | ||
}, | ||
], | ||
split_size: None, | ||
run: None, | ||
borderless: false, | ||
focus: None, | ||
external_children_index: None, | ||
}, | ||
), | ||
} |
60 changes: 60 additions & 0 deletions
60
...utils__input__layout__layout_test__close_on_exit_overrides_close_on_exit_in_template.snap
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,60 @@ | ||
--- | ||
source: zellij-utils/src/input/./unit/layout_test.rs | ||
assertion_line: 1064 | ||
expression: "format!(\"{:#?}\", layout)" | ||
--- | ||
Layout { | ||
tabs: [], | ||
focused_tab_index: None, | ||
template: Some( | ||
PaneLayout { | ||
children_split_direction: Horizontal, | ||
name: None, | ||
children: [ | ||
PaneLayout { | ||
children_split_direction: Horizontal, | ||
name: None, | ||
children: [], | ||
split_size: None, | ||
run: Some( | ||
Command( | ||
RunCommand { | ||
command: "tail", | ||
args: [], | ||
cwd: None, | ||
hold_on_close: true, | ||
}, | ||
), | ||
), | ||
borderless: false, | ||
focus: None, | ||
external_children_index: None, | ||
}, | ||
PaneLayout { | ||
children_split_direction: Horizontal, | ||
name: None, | ||
children: [], | ||
split_size: None, | ||
run: Some( | ||
Command( | ||
RunCommand { | ||
command: "tail", | ||
args: [], | ||
cwd: None, | ||
hold_on_close: false, | ||
}, | ||
), | ||
), | ||
borderless: false, | ||
focus: None, | ||
external_children_index: None, | ||
}, | ||
], | ||
split_size: None, | ||
run: None, | ||
borderless: false, | ||
focus: None, | ||
external_children_index: None, | ||
}, | ||
), | ||
} |
41 changes: 41 additions & 0 deletions
41
...ellij_utils__input__layout__layout_test__layout_with_command_panes_and_close_on_exit.snap
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,41 @@ | ||
--- | ||
source: zellij-utils/src/input/./unit/layout_test.rs | ||
assertion_line: 281 | ||
expression: "format!(\"{:#?}\", layout)" | ||
--- | ||
Layout { | ||
tabs: [], | ||
focused_tab_index: None, | ||
template: Some( | ||
PaneLayout { | ||
children_split_direction: Horizontal, | ||
name: None, | ||
children: [ | ||
PaneLayout { | ||
children_split_direction: Horizontal, | ||
name: None, | ||
children: [], | ||
split_size: None, | ||
run: Some( | ||
Command( | ||
RunCommand { | ||
command: "htop", | ||
args: [], | ||
cwd: None, | ||
hold_on_close: false, | ||
}, | ||
), | ||
), | ||
borderless: false, | ||
focus: None, | ||
external_children_index: None, | ||
}, | ||
], | ||
split_size: None, | ||
run: None, | ||
borderless: false, | ||
focus: None, | ||
external_children_index: None, | ||
}, | ||
), | ||
} |
Oops, something went wrong.