From 192e6fd31ece0c73f8962f4af620a2757a2c1a2e Mon Sep 17 00:00:00 2001 From: Aram Drevekenin Date: Wed, 2 Aug 2023 11:41:51 +0200 Subject: [PATCH] feat(ui): break pane to new tab and move panes between tabs (#2664) * prototype * some tests * break out floating pane * break out plugin panes * add keybind and fix some minor issues * remove cli * move pane to left/right tab * update ui * adjust ui * style(fmt): rustfmt * style(comment): remove commented code * update snapshots --- default-plugins/status-bar/src/second_line.rs | 7 +- ...ests__e2e__cases__mirrored_sessions-2.snap | 2 +- zellij-server/src/panes/floating_panes/mod.rs | 14 + zellij-server/src/panes/tiled_panes/mod.rs | 48 +- zellij-server/src/plugins/mod.rs | 1 + ...new_tabs_with_layout_plugin_command-2.snap | 5 +- ...__new_tabs_with_layout_plugin_command.snap | 5 +- zellij-server/src/pty.rs | 6 +- zellij-server/src/route.rs | 19 + zellij-server/src/screen.rs | 178 +++++- zellij-server/src/tab/layout_applier.rs | 98 ++-- zellij-server/src/tab/mod.rs | 32 +- zellij-server/src/unit/screen_tests.rs | 526 ++++++++++++++++-- ...an_break_floating_pane_to_a_new_tab-2.snap | 26 + ...an_break_floating_pane_to_a_new_tab-3.snap | 26 + ...an_break_floating_pane_to_a_new_tab-4.snap | 26 + ...an_break_floating_pane_to_a_new_tab-5.snap | 6 + ..._can_break_floating_pane_to_a_new_tab.snap | 26 + ...k_floating_plugin_pane_to_a_new_tab-2.snap | 26 + ...k_floating_plugin_pane_to_a_new_tab-3.snap | 26 + ...k_floating_plugin_pane_to_a_new_tab-4.snap | 26 + ...k_floating_plugin_pane_to_a_new_tab-5.snap | 26 + ...k_floating_plugin_pane_to_a_new_tab-6.snap | 26 + ...k_floating_plugin_pane_to_a_new_tab-7.snap | 26 + ...k_floating_plugin_pane_to_a_new_tab-8.snap | 6 + ...eak_floating_plugin_pane_to_a_new_tab.snap | 26 + ..._screen_can_break_pane_to_a_new_tab-2.snap | 26 + ..._screen_can_break_pane_to_a_new_tab-3.snap | 26 + ..._screen_can_break_pane_to_a_new_tab-4.snap | 26 + ..._screen_can_break_pane_to_a_new_tab-5.snap | 6 + ...s__screen_can_break_pane_to_a_new_tab.snap | 26 + ..._can_break_plugin_pane_to_a_new_tab-2.snap | 26 + ..._can_break_plugin_pane_to_a_new_tab-3.snap | 26 + ..._can_break_plugin_pane_to_a_new_tab-4.snap | 26 + ..._can_break_plugin_pane_to_a_new_tab-5.snap | 26 + ..._can_break_plugin_pane_to_a_new_tab-6.snap | 6 + ...en_can_break_plugin_pane_to_a_new_tab.snap | 26 + ...een_can_move_pane_to_a_new_tab_left-2.snap | 26 + ...een_can_move_pane_to_a_new_tab_left-3.snap | 26 + ...een_can_move_pane_to_a_new_tab_left-4.snap | 26 + ...een_can_move_pane_to_a_new_tab_left-5.snap | 6 + ...creen_can_move_pane_to_a_new_tab_left.snap | 26 + ...en_can_move_pane_to_a_new_tab_right-2.snap | 26 + ...en_can_move_pane_to_a_new_tab_right-3.snap | 26 + ...en_can_move_pane_to_a_new_tab_right-4.snap | 26 + ...en_can_move_pane_to_a_new_tab_right-5.snap | 6 + ...reen_can_move_pane_to_a_new_tab_right.snap | 26 + ...k_last_selectable_pane_to_a_new_tab-2.snap | 6 + ...eak_last_selectable_pane_to_a_new_tab.snap | 26 + ...end_cli_new_tab_action_default_params.snap | 4 + ...i_new_tab_action_with_name_and_layout.snap | 6 +- zellij-utils/assets/config/default.kdl | 3 + zellij-utils/src/errors.rs | 3 + zellij-utils/src/input/actions.rs | 3 + zellij-utils/src/input/layout.rs | 30 + ..._test__args_added_to_args_in_template.snap | 5 +- ..._test__args_override_args_in_template.snap | 5 +- ..._define_a_stack_with_an_expanded_pane.snap | 6 + ...define_stacked_children_for_pane_node.snap | 6 +- ...ne_stacked_children_for_pane_template.snap | 7 +- ...ad_swap_layouts_from_a_different_file.snap | 38 +- ...n_not_as_first_child_of_pane_template.snap | 14 +- ...en_not_as_first_child_of_tab_template.snap | 14 +- ...it_added_to_close_on_exit_in_template.snap | 5 +- ...t_overrides_close_on_exit_in_template.snap | 5 +- ..._and_pane_template_both_with_children.snap | 19 +- ...ut_test__cwd_added_to_cwd_in_template.snap | 5 +- ...ut_test__cwd_override_cwd_in_template.snap | 5 +- ...ayout__layout_test__env_var_expansion.snap | 12 +- ...epended_to_panes_with_and_without_cwd.snap | 6 +- ...ith_and_without_cwd_in_pane_templates.snap | 9 +- ...with_and_without_cwd_in_tab_templates.snap | 8 +- ...global_cwd_given_to_panes_without_cwd.snap | 5 +- ...al_cwd_passed_from_layout_constructor.snap | 5 +- ...r_overrides_global_cwd_in_layout_file.snap | 5 +- ...lobal_cwd_prepended_to_panes_with_cwd.snap | 5 +- ...th_tab_cwd_given_to_panes_without_cwd.snap | 6 +- ..._with_command_panes_and_close_on_exit.snap | 2 + ...ith_command_panes_and_start_suspended.snap | 2 + ...est__layout_with_default_tab_template.snap | 22 +- ...t_with_nested_branched_pane_templates.snap | 13 +- ...st__layout_with_nested_pane_templates.snap | 10 +- ...__layout_with_pane_excluded_from_sync.snap | 3 + ...yout_test__layout_with_pane_templates.snap | 24 +- ...t__layout_with_tab_and_pane_templates.snap | 9 +- ...__layout_with_tabs_and_floating_panes.snap | 8 + ...s_overriden_by_its_consumers_bare_cwd.snap | 4 +- ...verriden_by_its_consumers_command_cwd.snap | 4 +- ..._consumer_command_does_not_have_a_cwd.snap | 4 +- ...cwd_is_overriden_by_its_consumers_cwd.snap | 4 +- ...t_cwd_receives_its_consumers_bare_cwd.snap | 4 +- ...d_overriden_by_its_consumers_bare_cwd.snap | 4 +- ...ated_to_its_consumer_command_with_cwd.snap | 4 +- ...d_to_its_consumer_command_without_cwd.snap | 4 +- ..._bare_propagated_to_its_consumer_edit.snap | 3 + ...mmand_propagated_to_its_consumer_edit.snap | 3 + ...t__tab_cwd_given_to_panes_without_cwd.snap | 6 +- ...__tab_cwd_prepended_to_panes_with_cwd.snap | 6 +- zellij-utils/src/kdl/mod.rs | 3 + zellij-utils/src/pane_size.rs | 6 + ...i_arguments_override_layout_options-2.snap | 3 +- ...efault_config_with_no_cli_arguments-2.snap | 98 ++++ ..._default_config_with_no_cli_arguments.snap | 24 + ...out_env_vars_override_config_env_vars.snap | 24 + ...out_options_override_config_options-2.snap | 3 +- ...ayout_plugins_override_config_plugins.snap | 24 + ..._layout_themes_override_config_themes.snap | 24 + ..._ui_config_overrides_config_ui_config.snap | 24 + 108 files changed, 2200 insertions(+), 157 deletions(-) create mode 100644 zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_break_floating_pane_to_a_new_tab-2.snap create mode 100644 zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_break_floating_pane_to_a_new_tab-3.snap create mode 100644 zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_break_floating_pane_to_a_new_tab-4.snap create mode 100644 zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_break_floating_pane_to_a_new_tab-5.snap create mode 100644 zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_break_floating_pane_to_a_new_tab.snap create mode 100644 zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_break_floating_plugin_pane_to_a_new_tab-2.snap create mode 100644 zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_break_floating_plugin_pane_to_a_new_tab-3.snap create mode 100644 zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_break_floating_plugin_pane_to_a_new_tab-4.snap create mode 100644 zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_break_floating_plugin_pane_to_a_new_tab-5.snap create mode 100644 zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_break_floating_plugin_pane_to_a_new_tab-6.snap create mode 100644 zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_break_floating_plugin_pane_to_a_new_tab-7.snap create mode 100644 zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_break_floating_plugin_pane_to_a_new_tab-8.snap create mode 100644 zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_break_floating_plugin_pane_to_a_new_tab.snap create mode 100644 zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_break_pane_to_a_new_tab-2.snap create mode 100644 zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_break_pane_to_a_new_tab-3.snap create mode 100644 zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_break_pane_to_a_new_tab-4.snap create mode 100644 zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_break_pane_to_a_new_tab-5.snap create mode 100644 zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_break_pane_to_a_new_tab.snap create mode 100644 zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_break_plugin_pane_to_a_new_tab-2.snap create mode 100644 zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_break_plugin_pane_to_a_new_tab-3.snap create mode 100644 zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_break_plugin_pane_to_a_new_tab-4.snap create mode 100644 zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_break_plugin_pane_to_a_new_tab-5.snap create mode 100644 zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_break_plugin_pane_to_a_new_tab-6.snap create mode 100644 zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_break_plugin_pane_to_a_new_tab.snap create mode 100644 zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_move_pane_to_a_new_tab_left-2.snap create mode 100644 zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_move_pane_to_a_new_tab_left-3.snap create mode 100644 zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_move_pane_to_a_new_tab_left-4.snap create mode 100644 zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_move_pane_to_a_new_tab_left-5.snap create mode 100644 zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_move_pane_to_a_new_tab_left.snap create mode 100644 zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_move_pane_to_a_new_tab_right-2.snap create mode 100644 zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_move_pane_to_a_new_tab_right-3.snap create mode 100644 zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_move_pane_to_a_new_tab_right-4.snap create mode 100644 zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_move_pane_to_a_new_tab_right-5.snap create mode 100644 zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_move_pane_to_a_new_tab_right.snap create mode 100644 zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_cannot_break_last_selectable_pane_to_a_new_tab-2.snap create mode 100644 zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_cannot_break_last_selectable_pane_to_a_new_tab.snap diff --git a/default-plugins/status-bar/src/second_line.rs b/default-plugins/status-bar/src/second_line.rs index 015618f06f..e392317444 100644 --- a/default-plugins/status-bar/src/second_line.rs +++ b/default-plugins/status-bar/src/second_line.rs @@ -166,7 +166,12 @@ fn get_keys_and_hints(mi: &ModeInfo) -> Vec<(String, String, Vec)> { (s("Rename"), s("Rename"), action_key(&km, &[A::SwitchToMode(IM::RenameTab), A::TabNameInput(vec![0])])), (s("Sync"), s("Sync"), action_key(&km, &[A::ToggleActiveSyncTab, TO_NORMAL])), - (s("Toggle"), s("Toggle"), action_key(&km, &[A::ToggleTab])), + (s("Break pane to new tab"), s("Break"), action_key(&km, &[A::BreakPane, TO_NORMAL])), + (s("Break pane to next/prev tab"), s("Break next/prev"), + action_key_group(&km, &[ + &[A::BreakPaneLeft, TO_NORMAL], + &[A::BreakPaneRight, TO_NORMAL] + ])), (s("Select pane"), s("Select"), to_normal_key), ]} else if mi.mode == IM::Resize { vec![ (s("Increase/Decrease size"), s("Increase/Decrease"), diff --git a/src/tests/e2e/snapshots/zellij__tests__e2e__cases__mirrored_sessions-2.snap b/src/tests/e2e/snapshots/zellij__tests__e2e__cases__mirrored_sessions-2.snap index 205ff40c73..fa5d345aa9 100644 --- a/src/tests/e2e/snapshots/zellij__tests__e2e__cases__mirrored_sessions-2.snap +++ b/src/tests/e2e/snapshots/zellij__tests__e2e__cases__mirrored_sessions-2.snap @@ -26,4 +26,4 @@ expression: second_runner_snapshot │ ││ │ └──────────────────────────────────────────────────────────┘└──────────────────────────────────────────────────────────┘ Ctrl + LOCK 

PANE  TAB  RESIZE  MOVE  SEARCH  SESSION  QUIT  - New / <←→> Change focus / Close / Rename / Sync / Toggle / Select pane + New / <←→> Move / Close / Rename / Sync / Break / <[]> Break next/prev / Select diff --git a/zellij-server/src/panes/floating_panes/mod.rs b/zellij-server/src/panes/floating_panes/mod.rs index 98c6046bf6..2de5b74eb2 100644 --- a/zellij-server/src/panes/floating_panes/mod.rs +++ b/zellij-server/src/panes/floating_panes/mod.rs @@ -898,4 +898,18 @@ impl FloatingPanes { } pane_infos } + pub fn set_geom_for_pane_with_run(&mut self, run: Option, geom: PaneGeom) { + match self + .panes + .iter_mut() + .find(|(_, p)| p.invoked_with() == &run) + { + Some((_, pane)) => { + pane.set_geom(geom); + }, + None => { + log::error!("Failed to find pane with run: {:?}", run); + }, + } + } } diff --git a/zellij-server/src/panes/tiled_panes/mod.rs b/zellij-server/src/panes/tiled_panes/mod.rs index f0a6e8436a..9aca1af4ae 100644 --- a/zellij-server/src/panes/tiled_panes/mod.rs +++ b/zellij-server/src/panes/tiled_panes/mod.rs @@ -182,9 +182,13 @@ impl TiledPanes { let has_room_for_new_pane = pane_grid .find_room_for_new_pane(cursor_height_width_ratio) .is_some(); - has_room_for_new_pane || pane_grid.has_room_for_new_stacked_pane() + has_room_for_new_pane || pane_grid.has_room_for_new_stacked_pane() || self.panes.is_empty() } fn add_pane(&mut self, pane_id: PaneId, mut pane: Box, should_relayout: bool) { + if self.panes.is_empty() { + self.panes.insert(pane_id, pane); + return; + } let cursor_height_width_ratio = self.cursor_height_width_ratio(); let mut pane_grid = TiledPaneGrid::new( &mut self.panes, @@ -250,6 +254,19 @@ impl TiledPanes { }) .collect() } + pub fn non_selectable_pane_geoms_inside_viewport(&self) -> Vec { + self.panes + .values() + .filter_map(|p| { + let geom = p.position_and_size(); + if !p.selectable() && is_inside_viewport(&self.viewport.borrow(), p) { + Some(geom.into()) + } else { + None + } + }) + .collect() + } pub fn first_selectable_pane_id(&self) -> Option { self.panes .iter() @@ -587,8 +604,6 @@ impl TiledPanes { pub fn focused_pane_id(&self, client_id: ClientId) -> Option { self.active_panes.get(&client_id).copied() } - // FIXME: Really not a fan of allowing this... Someone with more energy - // than me should clean this up someday... #[allow(clippy::borrowed_box)] pub fn get_pane(&self, pane_id: PaneId) -> Option<&Box> { self.panes.get(&pane_id) @@ -735,6 +750,29 @@ impl TiledPanes { pub fn get_panes(&self) -> impl Iterator)> { self.panes.iter() } + pub fn set_geom_for_pane_with_run( + &mut self, + run: Option, + geom: PaneGeom, + borderless: bool, + ) { + match self + .panes + .iter_mut() + .find(|(_, p)| p.invoked_with() == &run) + { + Some((_, pane)) => { + pane.set_geom(geom); + pane.set_borderless(borderless); + if self.draw_pane_frames { + pane.set_content_offset(Offset::frame(1)); + } + }, + None => { + log::error!("Failed to find pane with run: {:?}", run); + }, + } + } pub fn resize(&mut self, new_screen_size: Size) { // this is blocked out to appease the borrow checker { @@ -1501,11 +1539,11 @@ impl TiledPanes { self.set_pane_frames(self.draw_pane_frames); // recalculate pane frames and update size closed_pane } else { - self.panes.remove(&pane_id); + let closed_pane = self.panes.remove(&pane_id); // this is a bit of a roundabout way to say: this is the last pane and so the tab // should be destroyed self.active_panes.clear(&mut self.panes); - None + closed_pane } } pub fn hold_pane( diff --git a/zellij-server/src/plugins/mod.rs b/zellij-server/src/plugins/mod.rs index 7791880f27..f36bdc2d2e 100644 --- a/zellij-server/src/plugins/mod.rs +++ b/zellij-server/src/plugins/mod.rs @@ -228,6 +228,7 @@ pub(crate) fn plugin_thread_main( }; let mut extracted_floating_plugins: Vec> = floating_panes_layout .iter() + .filter(|f| !f.already_running) .map(|f| f.run.clone()) .collect(); extracted_run_instructions.append(&mut extracted_floating_plugins); diff --git a/zellij-server/src/plugins/unit/snapshots/zellij_server__plugins__plugin_tests__new_tabs_with_layout_plugin_command-2.snap b/zellij-server/src/plugins/unit/snapshots/zellij_server__plugins__plugin_tests__new_tabs_with_layout_plugin_command-2.snap index e165dab102..43571f91f7 100644 --- a/zellij-server/src/plugins/unit/snapshots/zellij_server__plugins__plugin_tests__new_tabs_with_layout_plugin_command-2.snap +++ b/zellij-server/src/plugins/unit/snapshots/zellij_server__plugins__plugin_tests__new_tabs_with_layout_plugin_command-2.snap @@ -1,6 +1,6 @@ --- source: zellij-server/src/plugins/./unit/plugin_tests.rs -assertion_line: 521 +assertion_line: 735 expression: "format!(\"{:#?}\", second_new_tab_event)" --- Some( @@ -24,6 +24,7 @@ Some( children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -37,6 +38,7 @@ Some( children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -47,6 +49,7 @@ Some( children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ), [], diff --git a/zellij-server/src/plugins/unit/snapshots/zellij_server__plugins__plugin_tests__new_tabs_with_layout_plugin_command.snap b/zellij-server/src/plugins/unit/snapshots/zellij_server__plugins__plugin_tests__new_tabs_with_layout_plugin_command.snap index af83de3269..5e9a17cb31 100644 --- a/zellij-server/src/plugins/unit/snapshots/zellij_server__plugins__plugin_tests__new_tabs_with_layout_plugin_command.snap +++ b/zellij-server/src/plugins/unit/snapshots/zellij_server__plugins__plugin_tests__new_tabs_with_layout_plugin_command.snap @@ -1,6 +1,6 @@ --- source: zellij-server/src/plugins/./unit/plugin_tests.rs -assertion_line: 520 +assertion_line: 734 expression: "format!(\"{:#?}\", first_new_tab_event)" --- Some( @@ -24,6 +24,7 @@ Some( children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -37,6 +38,7 @@ Some( children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -47,6 +49,7 @@ Some( children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ), [], diff --git a/zellij-server/src/pty.rs b/zellij-server/src/pty.rs index 84f282f8de..f571d4381d 100644 --- a/zellij-server/src/pty.rs +++ b/zellij-server/src/pty.rs @@ -605,8 +605,10 @@ impl Pty { default_shell.unwrap_or_else(|| self.get_default_terminal(cwd, None)); self.fill_cwd(&mut default_shell, client_id); let extracted_run_instructions = layout.extract_run_instructions(); - let extracted_floating_run_instructions = - floating_panes_layout.iter().map(|f| f.run.clone()); + let extracted_floating_run_instructions = floating_panes_layout + .iter() + .filter(|f| !f.already_running) + .map(|f| f.run.clone()); let mut new_pane_pids: Vec<(u32, bool, Option, Result)> = vec![]; // (terminal_id, // starts_held, // run_command, diff --git a/zellij-server/src/route.rs b/zellij-server/src/route.rs index e1575e7fc2..603233ff1c 100644 --- a/zellij-server/src/route.rs +++ b/zellij-server/src/route.rs @@ -690,6 +690,25 @@ pub(crate) fn route_action( )) .with_context(err_context)?; }, + Action::BreakPane => { + senders + .send_to_screen(ScreenInstruction::BreakPane( + default_layout.clone(), + default_shell.clone(), + client_id, + )) + .with_context(err_context)?; + }, + Action::BreakPaneRight => { + senders + .send_to_screen(ScreenInstruction::BreakPaneRight(client_id)) + .with_context(err_context)?; + }, + Action::BreakPaneLeft => { + senders + .send_to_screen(ScreenInstruction::BreakPaneLeft(client_id)) + .with_context(err_context)?; + }, } Ok(should_break) } diff --git a/zellij-server/src/screen.rs b/zellij-server/src/screen.rs index 6d93ee2c4c..4d5775f7da 100644 --- a/zellij-server/src/screen.rs +++ b/zellij-server/src/screen.rs @@ -14,12 +14,13 @@ use zellij_utils::pane_size::{Size, SizeInPixels}; use zellij_utils::{ input::command::TerminalAction, input::layout::{ - FloatingPaneLayout, PluginUserConfiguration, Run, RunPlugin, RunPluginLocation, - SwapFloatingLayout, SwapTiledLayout, TiledPaneLayout, + FloatingPaneLayout, Layout, Run, RunPlugin, RunPluginLocation, SwapFloatingLayout, + SwapTiledLayout, TiledPaneLayout, }, position::Position, }; +use crate::background_jobs::BackgroundJob; use crate::os_input_output::ResizeCache; use crate::panes::alacritty_functions::xparse_color; use crate::panes::terminal_character::AnsiCode; @@ -279,6 +280,9 @@ pub enum ScreenInstruction { FocusPaneWithId(PaneId, bool, ClientId), // bool is should_float RenamePane(PaneId, Vec), RenameTab(usize, Vec), + BreakPane(Box, Option, ClientId), + BreakPaneRight(ClientId), + BreakPaneLeft(ClientId), } impl From<&ScreenInstruction> for ScreenContext { @@ -446,6 +450,9 @@ impl From<&ScreenInstruction> for ScreenContext { ScreenInstruction::FocusPaneWithId(..) => ScreenContext::FocusPaneWithId, ScreenInstruction::RenamePane(..) => ScreenContext::RenamePane, ScreenInstruction::RenameTab(..) => ScreenContext::RenameTab, + ScreenInstruction::BreakPane(..) => ScreenContext::BreakPane, + ScreenInstruction::BreakPaneRight(..) => ScreenContext::BreakPaneRight, + ScreenInstruction::BreakPaneLeft(..) => ScreenContext::BreakPaneLeft, } } } @@ -609,6 +616,7 @@ impl Screen { &mut self, source_tab_index: usize, destination_tab_index: usize, + update_mode_infos: bool, clients_to_move: Option>, ) -> Result<()> { let err_context = || { @@ -629,9 +637,11 @@ impl Screen { destination_tab .add_multiple_clients(client_mode_info_in_source_tab) .with_context(err_context)?; - destination_tab - .update_input_modes() - .with_context(err_context)?; + if update_mode_infos { + destination_tab + .update_input_modes() + .with_context(err_context)?; + } destination_tab.set_force_render(); destination_tab.visible(true).with_context(err_context)?; } @@ -657,6 +667,7 @@ impl Screen { &mut self, new_tab_pos: usize, should_change_pane_focus: Option, + update_mode_infos: bool, client_id: ClientId, ) -> Result<()> { let err_context = || { @@ -676,8 +687,13 @@ impl Screen { let current_tab_index = current_tab.index; let new_tab_index = new_tab.index; if self.session_is_mirrored { - self.move_clients_between_tabs(current_tab_index, new_tab_index, None) - .with_context(err_context)?; + self.move_clients_between_tabs( + current_tab_index, + new_tab_index, + update_mode_infos, + None, + ) + .with_context(err_context)?; let all_connected_clients: Vec = self.connected_clients.borrow().iter().copied().collect(); for client_id in all_connected_clients { @@ -696,6 +712,7 @@ impl Screen { self.move_clients_between_tabs( current_tab_index, new_tab_index, + update_mode_infos, Some(vec![client_id]), ) .with_context(err_context)?; @@ -736,7 +753,7 @@ impl Screen { fn switch_active_tab_name(&mut self, name: String, client_id: ClientId) -> Result { match self.tabs.values().find(|t| t.name == name) { Some(new_tab) => { - self.switch_active_tab(new_tab.position, None, client_id)?; + self.switch_active_tab(new_tab.position, None, true, client_id)?; Ok(true) }, None => Ok(false), @@ -747,6 +764,7 @@ impl Screen { pub fn switch_tab_next( &mut self, should_change_pane_focus: Option, + update_mode_infos: bool, client_id: ClientId, ) -> Result<()> { let err_context = || format!("failed to switch to next tab for client {client_id}"); @@ -765,6 +783,7 @@ impl Screen { return self.switch_active_tab( new_tab_pos, should_change_pane_focus, + update_mode_infos, client_id, ); }, @@ -778,6 +797,7 @@ impl Screen { pub fn switch_tab_prev( &mut self, should_change_pane_focus: Option, + update_mode_infos: bool, client_id: ClientId, ) -> Result<()> { let err_context = || format!("failed to switch to previous tab for client {client_id}"); @@ -801,6 +821,7 @@ impl Screen { return self.switch_active_tab( new_tab_pos, should_change_pane_focus, + update_mode_infos, client_id, ); }, @@ -811,7 +832,7 @@ impl Screen { } pub fn go_to_tab(&mut self, tab_index: usize, client_id: ClientId) -> Result<()> { - self.switch_active_tab(tab_index.saturating_sub(1), None, client_id) + self.switch_active_tab(tab_index.saturating_sub(1), None, true, client_id) } pub fn go_to_tab_name(&mut self, name: String, client_id: ClientId) -> Result { @@ -1389,6 +1410,7 @@ impl Screen { for tab in self.tabs.values_mut() { tab.change_mode_info(mode_info.clone(), client_id); tab.mark_active_pane_for_rerender(client_id); + tab.update_input_modes()?; } if let Some(os_input) = &mut self.bus.os_input { @@ -1433,7 +1455,7 @@ impl Screen { .move_focus_left(client_id) .and_then(|success| { if !success { - self.switch_tab_prev(Some(Direction::Left), client_id) + self.switch_tab_prev(Some(Direction::Left), true, client_id) .context("failed to move focus to previous tab") } else { Ok(()) @@ -1468,7 +1490,7 @@ impl Screen { .move_focus_right(client_id) .and_then(|success| { if !success { - self.switch_tab_next(Some(Direction::Right), client_id) + self.switch_tab_next(Some(Direction::Right), true, client_id) .context("failed to move focus to next tab") } else { Ok(()) @@ -1555,6 +1577,127 @@ impl Screen { }; Ok(()) } + pub fn break_pane( + &mut self, + default_shell: Option, + default_layout: Box, + client_id: ClientId, + ) -> Result<()> { + let err_context = || "failed break pane out of tab".to_string(); + let active_tab = self.get_active_tab_mut(client_id)?; + if active_tab.get_selectable_tiled_panes_count() > 1 + || active_tab.get_visible_selectable_floating_panes_count() > 0 + { + let active_pane_id = active_tab + .get_active_pane_id(client_id) + .with_context(err_context)?; + let pane_to_break_is_floating = active_tab.are_floating_panes_visible(); + let active_pane = active_tab + .close_pane(active_pane_id, false, Some(client_id)) + .with_context(err_context)?; + let active_pane_run_instruction = active_pane.invoked_with().clone(); + let tab_index = self.get_new_tab_index(); + let swap_layouts = ( + default_layout.swap_tiled_layouts.clone(), + default_layout.swap_floating_layouts.clone(), + ); + self.new_tab(tab_index, swap_layouts, None, client_id)?; + let tab = self.tabs.get_mut(&tab_index).with_context(err_context)?; + let (mut tiled_panes_layout, mut floating_panes_layout) = default_layout.new_tab(); + if pane_to_break_is_floating { + tab.show_floating_panes(); + tab.add_floating_pane(active_pane, active_pane_id, Some(client_id))?; + if let Some(mut already_running_layout) = floating_panes_layout + .iter_mut() + .find(|i| i.run == active_pane_run_instruction) + { + already_running_layout.already_running = true; + } + } else { + tab.add_tiled_pane(active_pane, active_pane_id, Some(client_id))?; + tiled_panes_layout.ignore_run_instruction(active_pane_run_instruction.clone()); + } + self.bus.senders.send_to_plugin(PluginInstruction::NewTab( + None, + default_shell, + Some(tiled_panes_layout), + floating_panes_layout, + tab_index, + client_id, + ))?; + } else { + let active_pane_id = active_tab + .get_active_pane_id(client_id) + .with_context(err_context)?; + self.bus + .senders + .send_to_background_jobs(BackgroundJob::DisplayPaneError( + vec![active_pane_id], + "Cannot break single pane out!".into(), + )) + .with_context(err_context)?; + self.unblock_input()?; + } + Ok(()) + } + pub fn break_pane_to_new_tab( + &mut self, + direction: Direction, + client_id: ClientId, + ) -> Result<()> { + let err_context = || "failed break pane out of tab".to_string(); + if self.tabs.len() > 1 { + let (active_pane_id, active_pane, pane_to_break_is_floating) = { + let active_tab = self.get_active_tab_mut(client_id)?; + let active_pane_id = active_tab + .get_active_pane_id(client_id) + .with_context(err_context)?; + let pane_to_break_is_floating = active_tab.are_floating_panes_visible(); + let active_pane = active_tab + .close_pane(active_pane_id, false, Some(client_id)) + .with_context(err_context)?; + (active_pane_id, active_pane, pane_to_break_is_floating) + }; + let update_mode_infos = false; + match direction { + Direction::Right | Direction::Down => { + self.switch_tab_next(None, update_mode_infos, client_id)?; + }, + Direction::Left | Direction::Up => { + self.switch_tab_prev(None, update_mode_infos, client_id)?; + }, + }; + let new_active_tab = self.get_active_tab_mut(client_id)?; + + if pane_to_break_is_floating { + new_active_tab.show_floating_panes(); + new_active_tab.add_floating_pane(active_pane, active_pane_id, Some(client_id))?; + } else { + new_active_tab.hide_floating_panes(); + new_active_tab.add_tiled_pane(active_pane, active_pane_id, Some(client_id))?; + } + + self.report_tab_state()?; + self.report_pane_state()?; + } else { + let active_pane_id = { + let active_tab = self.get_active_tab_mut(client_id)?; + active_tab + .get_active_pane_id(client_id) + .with_context(err_context)? + }; + self.bus + .senders + .send_to_background_jobs(BackgroundJob::DisplayPaneError( + vec![active_pane_id], + "No other tabs to add pane to!".into(), + )) + .with_context(err_context)?; + } + self.unblock_input()?; + self.render()?; + Ok(()) + } fn unblock_input(&self) -> Result<()> { self.bus @@ -2234,12 +2377,12 @@ pub(crate) fn screen_thread_main( screen.report_pane_state()?; }, ScreenInstruction::SwitchTabNext(client_id) => { - screen.switch_tab_next(None, client_id)?; + screen.switch_tab_next(None, true, client_id)?; screen.unblock_input()?; screen.render()?; }, ScreenInstruction::SwitchTabPrev(client_id) => { - screen.switch_tab_prev(None, client_id)?; + screen.switch_tab_prev(None, true, client_id)?; screen.unblock_input()?; screen.render()?; }, @@ -2815,6 +2958,15 @@ pub(crate) fn screen_thread_main( } screen.report_tab_state()?; }, + ScreenInstruction::BreakPane(default_layout, default_shell, client_id) => { + screen.break_pane(default_shell, default_layout, client_id)?; + }, + ScreenInstruction::BreakPaneRight(client_id) => { + screen.break_pane_to_new_tab(Direction::Right, client_id)?; + }, + ScreenInstruction::BreakPaneLeft(client_id) => { + screen.break_pane_to_new_tab(Direction::Left, client_id)?; + }, } } Ok(()) diff --git a/zellij-server/src/tab/layout_applier.rs b/zellij-server/src/tab/layout_applier.rs index 4797e8f37c..b93bb52fd9 100644 --- a/zellij-server/src/tab/layout_applier.rs +++ b/zellij-server/src/tab/layout_applier.rs @@ -180,6 +180,11 @@ impl<'a> LayoutApplier<'a> { } } pane_focuser.focus_tiled_pane(&mut self.tiled_panes); + LayoutApplier::offset_viewport( + self.viewport.clone(), + self.tiled_panes, + self.draw_pane_frames, + ); }, Err(e) => { Err::<(), _>(anyError::msg(e)) @@ -200,6 +205,7 @@ impl<'a> LayoutApplier<'a> { let free_space = self.total_space_for_tiled_panes(); match layout.position_panes_in_space(&free_space, None) { Ok(positions_in_layout) => { + let mut run_instructions_to_ignore = layout.run_instructions_to_ignore.clone(); let positions_and_size = positions_in_layout.iter(); let mut new_terminal_ids = new_terminal_ids.iter(); @@ -211,8 +217,17 @@ impl<'a> LayoutApplier<'a> { }; for (layout, position_and_size) in positions_and_size { - // A plugin pane - if let Some(Run::Plugin(run)) = layout.run.clone() { + if let Some(position) = run_instructions_to_ignore + .iter() + .position(|r| r == &layout.run) + { + let run = run_instructions_to_ignore.remove(position); + self.tiled_panes.set_geom_for_pane_with_run( + run, + *position_and_size, + layout.borderless, + ); + } else if let Some(Run::Plugin(run)) = layout.run.clone() { let pane_title = run.location.to_string(); let pid = new_plugin_ids .get_mut(&run.location) @@ -320,10 +335,15 @@ impl<'a> LayoutApplier<'a> { let mut new_floating_terminal_ids = new_floating_terminal_ids.iter(); for floating_pane_layout in floating_panes_layout { layout_has_floating_panes = true; - if let Some(Run::Plugin(run)) = floating_pane_layout.run.clone() { - let position_and_size = self - .floating_panes - .position_floating_pane_layout(&floating_pane_layout); + let position_and_size = self + .floating_panes + .position_floating_pane_layout(&floating_pane_layout); + if floating_pane_layout.already_running { + self.floating_panes.set_geom_for_pane_with_run( + floating_pane_layout.run.clone(), + position_and_size, + ); + } else if let Some(Run::Plugin(run)) = floating_pane_layout.run.clone() { let pane_title = run.location.to_string(); let pid = new_plugin_ids .get_mut(&run.location) @@ -363,9 +383,6 @@ impl<'a> LayoutApplier<'a> { focused_floating_pane = Some(PaneId::Plugin(pid)); } } else if let Some((pid, hold_for_command)) = new_floating_terminal_ids.next() { - let position_and_size = self - .floating_panes - .position_floating_pane_layout(&floating_pane_layout); let next_terminal_position = get_next_terminal_position(&self.tiled_panes, &self.floating_panes); let initial_title = match &floating_pane_layout.run { @@ -504,28 +521,43 @@ impl<'a> LayoutApplier<'a> { self.tiled_panes.resize(new_screen_size); Ok(()) } - fn offset_viewport(&mut self, position_and_size: &Viewport) { - let mut viewport = self.viewport.borrow_mut(); - if position_and_size.x == viewport.x - && position_and_size.x + position_and_size.cols == viewport.x + viewport.cols - { - if position_and_size.y == viewport.y { - viewport.y += position_and_size.rows; - viewport.rows -= position_and_size.rows; - } else if position_and_size.y + position_and_size.rows == viewport.y + viewport.rows { - viewport.rows -= position_and_size.rows; - } - } - if position_and_size.y == viewport.y - && position_and_size.y + position_and_size.rows == viewport.y + viewport.rows + pub fn offset_viewport( + viewport: Rc>, + tiled_panes: &mut TiledPanes, + draw_pane_frames: bool, + ) { + let boundary_geoms = tiled_panes.non_selectable_pane_geoms_inside_viewport(); { - if position_and_size.x == viewport.x { - viewport.x += position_and_size.cols; - viewport.cols -= position_and_size.cols; - } else if position_and_size.x + position_and_size.cols == viewport.x + viewport.cols { - viewport.cols -= position_and_size.cols; + // curly braces here is so that we free viewport immediately when we're done + let mut viewport = viewport.borrow_mut(); + for position_and_size in boundary_geoms { + if position_and_size.x == viewport.x + && position_and_size.x + position_and_size.cols == viewport.x + viewport.cols + { + if position_and_size.y == viewport.y { + viewport.y += position_and_size.rows; + viewport.rows -= position_and_size.rows; + } else if position_and_size.y + position_and_size.rows + == viewport.y + viewport.rows + { + viewport.rows -= position_and_size.rows; + } + } + if position_and_size.y == viewport.y + && position_and_size.y + position_and_size.rows == viewport.y + viewport.rows + { + if position_and_size.x == viewport.x { + viewport.x += position_and_size.cols; + viewport.cols -= position_and_size.cols; + } else if position_and_size.x + position_and_size.cols + == viewport.x + viewport.cols + { + viewport.cols -= position_and_size.cols; + } + } } } + tiled_panes.set_pane_frames(draw_pane_frames); } fn adjust_viewport(&mut self) -> Result<()> { // here we offset the viewport after applying a tiled panes layout @@ -541,11 +573,11 @@ impl<'a> LayoutApplier<'a> { *display_area }; self.resize_whole_tab(display_area).context(err_context)?; - let boundary_geoms = self.tiled_panes.borderless_pane_geoms(); - for geom in boundary_geoms { - self.offset_viewport(&geom) - } - self.tiled_panes.set_pane_frames(self.draw_pane_frames); + LayoutApplier::offset_viewport( + self.viewport.clone(), + self.tiled_panes, + self.draw_pane_frames, + ); Ok(()) } fn set_focused_tiled_pane(&mut self, focus_pane_id: Option, client_id: ClientId) { diff --git a/zellij-server/src/tab/mod.rs b/zellij-server/src/tab/mod.rs index ed82d617d1..20fbaaca29 100644 --- a/zellij-server/src/tab/mod.rs +++ b/zellij-server/src/tab/mod.rs @@ -1780,9 +1780,25 @@ impl Tab { fn get_tiled_panes(&self) -> impl Iterator)> { self.tiled_panes.get_panes() } + fn get_floating_panes(&self) -> impl Iterator)> { + self.floating_panes.get_panes() + } fn get_selectable_tiled_panes(&self) -> impl Iterator)> { self.get_tiled_panes().filter(|(_, p)| p.selectable()) } + fn get_selectable_floating_panes(&self) -> impl Iterator)> { + self.get_floating_panes().filter(|(_, p)| p.selectable()) + } + pub fn get_selectable_tiled_panes_count(&self) -> usize { + self.get_selectable_tiled_panes().count() + } + pub fn get_visible_selectable_floating_panes_count(&self) -> usize { + if self.are_floating_panes_visible() { + self.get_selectable_floating_panes().count() + } else { + 0 + } + } fn get_next_terminal_position(&self) -> usize { let tiled_panes_count = self .tiled_panes @@ -2142,6 +2158,13 @@ impl Tab { self.tiled_panes.move_clients_out_of_pane(id); } } + // we do this here because if there is a non-selectable pane on the edge, we consider it + // outside the viewport (a ui-pane, eg. the status-bar and tab-bar) and need to adjust for it + LayoutApplier::offset_viewport( + self.viewport.clone(), + &mut self.tiled_panes, + self.draw_pane_frames, + ); } pub fn close_pane( &mut self, @@ -3137,6 +3160,7 @@ impl Tab { pub fn set_pane_frames(&mut self, should_set_pane_frames: bool) { self.tiled_panes.set_pane_frames(should_set_pane_frames); + self.draw_pane_frames = should_set_pane_frames; self.should_clear_display_before_rendering = true; self.set_force_render(); } @@ -3278,13 +3302,13 @@ impl Tab { plugin_pane.progress_animation_offset(); } } - fn show_floating_panes(&mut self) { + pub fn show_floating_panes(&mut self) { // this function is to be preferred to directly invoking floating_panes.toggle_show_panes(true) self.floating_panes.toggle_show_panes(true); self.tiled_panes.unfocus_all_panes(); } - fn hide_floating_panes(&mut self) { + pub fn hide_floating_panes(&mut self) { // this function is to be preferred to directly invoking // floating_panes.toggle_show_panes(false) self.floating_panes.toggle_show_panes(false); @@ -3355,7 +3379,7 @@ impl Tab { } pane_info } - fn add_floating_pane( + pub fn add_floating_pane( &mut self, mut pane: Box, pane_id: PaneId, @@ -3380,7 +3404,7 @@ impl Tab { } Ok(()) } - fn add_tiled_pane( + pub fn add_tiled_pane( &mut self, mut pane: Box, pane_id: PaneId, diff --git a/zellij-server/src/unit/screen_tests.rs b/zellij-server/src/unit/screen_tests.rs index 8a683edc0f..8d1debd353 100644 --- a/zellij-server/src/unit/screen_tests.rs +++ b/zellij-server/src/unit/screen_tests.rs @@ -15,7 +15,7 @@ use zellij_utils::errors::{prelude::*, ErrorContext}; use zellij_utils::input::actions::Action; use zellij_utils::input::command::{RunCommand, TerminalAction}; use zellij_utils::input::layout::{ - Layout, Run, RunPlugin, RunPluginLocation, SplitDirection, TiledPaneLayout, + FloatingPaneLayout, Layout, Run, RunPlugin, RunPluginLocation, SplitDirection, TiledPaneLayout, }; use zellij_utils::input::options::Options; use zellij_utils::ipc::IpcReceiverWithContext; @@ -271,7 +271,11 @@ struct MockScreen { } impl MockScreen { - pub fn run(&mut self, initial_layout: Option) -> std::thread::JoinHandle<()> { + pub fn run( + &mut self, + initial_layout: Option, + initial_floating_panes_layout: Vec, + ) -> std::thread::JoinHandle<()> { let config_options = self.config_options.clone(); let client_attributes = self.client_attributes.clone(); let screen_bus = Bus::new( @@ -302,7 +306,9 @@ impl MockScreen { .unwrap(); let pane_layout = initial_layout.unwrap_or_default(); let pane_count = pane_layout.extract_run_instructions().len(); + let floating_pane_count = initial_floating_panes_layout.len(); let mut pane_ids = vec![]; + let mut floating_pane_ids = vec![]; let mut plugin_ids = HashMap::new(); plugin_ids.insert( RunPluginLocation::File(PathBuf::from("/path/to/fake/plugin")), @@ -311,6 +317,9 @@ impl MockScreen { for i in 0..pane_count { pane_ids.push((i as u32, None)); } + for i in 0..floating_pane_count { + floating_pane_ids.push((i as u32, None)); + } let default_shell = None; let tab_name = None; let tab_index = self.last_opened_tab_index.map(|l| l + 1).unwrap_or(0); @@ -318,16 +327,19 @@ impl MockScreen { None, default_shell, Some(pane_layout.clone()), - vec![], // floating_panes_layout + initial_floating_panes_layout.clone(), + // vec![], // floating_panes_layout tab_name, (vec![], vec![]), // swap layouts self.main_client_id, )); let _ = self.to_screen.send(ScreenInstruction::ApplyLayout( pane_layout, - vec![], // floating panes layout + initial_floating_panes_layout, + // vec![], // floating panes layout pane_ids, - vec![], // floating pane ids + floating_pane_ids, + // vec![], // floating pane ids plugin_ids, tab_index, self.main_client_id, @@ -547,7 +559,7 @@ pub fn switch_to_prev_tab() { new_tab(&mut screen, 1, 1); new_tab(&mut screen, 2, 2); - screen.switch_tab_prev(None, 1).expect("TEST"); + screen.switch_tab_prev(None, true, 1).expect("TEST"); assert_eq!( screen.get_active_tab(1).unwrap().position, @@ -566,8 +578,8 @@ pub fn switch_to_next_tab() { new_tab(&mut screen, 1, 1); new_tab(&mut screen, 2, 2); - screen.switch_tab_prev(None, 1).expect("TEST"); - screen.switch_tab_next(None, 1).expect("TEST"); + screen.switch_tab_prev(None, true, 1).expect("TEST"); + screen.switch_tab_next(None, true, 1).expect("TEST"); assert_eq!( screen.get_active_tab(1).unwrap().position, @@ -641,7 +653,7 @@ pub fn close_the_middle_tab() { new_tab(&mut screen, 1, 1); new_tab(&mut screen, 2, 2); new_tab(&mut screen, 3, 3); - screen.switch_tab_prev(None, 1).expect("TEST"); + screen.switch_tab_prev(None, true, 1).expect("TEST"); screen.close_tab(1).expect("TEST"); assert_eq!(screen.tabs.len(), 2, "Two tabs left"); @@ -663,7 +675,7 @@ fn move_focus_left_at_left_screen_edge_changes_tab() { new_tab(&mut screen, 1, 1); new_tab(&mut screen, 2, 2); new_tab(&mut screen, 3, 3); - screen.switch_tab_prev(None, 1).expect("TEST"); + screen.switch_tab_prev(None, true, 1).expect("TEST"); screen.move_focus_left_or_previous_tab(1).expect("TEST"); assert_eq!( @@ -684,7 +696,7 @@ fn move_focus_right_at_right_screen_edge_changes_tab() { new_tab(&mut screen, 1, 1); new_tab(&mut screen, 2, 2); new_tab(&mut screen, 3, 3); - screen.switch_tab_prev(None, 1).expect("TEST"); + screen.switch_tab_prev(None, true, 1).expect("TEST"); screen.move_focus_right_or_next_tab(1).expect("TEST"); assert_eq!( @@ -820,7 +832,7 @@ pub fn toggle_to_previous_tab_delete() { "Active tab toggler to previous tab" ); - screen.switch_tab_prev(None, 1).expect("TEST"); + screen.switch_tab_prev(None, true, 1).expect("TEST"); assert_eq!( screen.tab_history.get(&1).unwrap(), &[0, 1, 3], @@ -831,7 +843,7 @@ pub fn toggle_to_previous_tab_delete() { 2, "Active tab toggler to previous tab" ); - screen.switch_tab_prev(None, 1).expect("TEST"); + screen.switch_tab_prev(None, true, 1).expect("TEST"); assert_eq!( screen.tab_history.get(&1).unwrap(), &[0, 3, 2], @@ -886,7 +898,7 @@ fn switch_to_tab_with_fullscreen() { } new_tab(&mut screen, 2, 2); - screen.switch_tab_prev(None, 1).expect("TEST"); + screen.switch_tab_prev(None, true, 1).expect("TEST"); assert_eq!( screen.get_active_tab(1).unwrap().position, @@ -1023,7 +1035,7 @@ pub fn send_cli_write_chars_action_to_screen() { let mut mock_screen = MockScreen::new(size); let pty_writer_receiver = mock_screen.pty_writer_receiver.take().unwrap(); let session_metadata = mock_screen.clone_session_metadata(); - let screen_thread = mock_screen.run(None); + let screen_thread = mock_screen.run(None, vec![]); let received_pty_instructions = Arc::new(Mutex::new(vec![])); let pty_writer_thread = log_actions_in_thread!( received_pty_instructions, @@ -1049,7 +1061,7 @@ pub fn send_cli_write_action_to_screen() { let mut mock_screen = MockScreen::new(size); let pty_writer_receiver = mock_screen.pty_writer_receiver.take().unwrap(); let session_metadata = mock_screen.clone_session_metadata(); - let screen_thread = mock_screen.run(None); + let screen_thread = mock_screen.run(None, vec![]); let received_pty_instructions = Arc::new(Mutex::new(vec![])); let pty_writer_thread = log_actions_in_thread!( received_pty_instructions, @@ -1074,7 +1086,7 @@ pub fn send_cli_resize_action_to_screen() { initial_layout.children = vec![TiledPaneLayout::default(), TiledPaneLayout::default()]; let mut mock_screen = MockScreen::new(size); let session_metadata = mock_screen.clone_session_metadata(); - let screen_thread = mock_screen.run(Some(initial_layout)); + let screen_thread = mock_screen.run(Some(initial_layout), vec![]); let received_server_instructions = Arc::new(Mutex::new(vec![])); let server_receiver = mock_screen.server_receiver.take().unwrap(); let pty_writer_thread = log_actions_in_thread!( @@ -1108,7 +1120,7 @@ pub fn send_cli_focus_next_pane_action() { initial_layout.children = vec![TiledPaneLayout::default(), TiledPaneLayout::default()]; let mut mock_screen = MockScreen::new(size); let session_metadata = mock_screen.clone_session_metadata(); - let screen_thread = mock_screen.run(Some(initial_layout)); + let screen_thread = mock_screen.run(Some(initial_layout), vec![]); let received_server_instructions = Arc::new(Mutex::new(vec![])); let server_receiver = mock_screen.server_receiver.take().unwrap(); let server_instruction = log_actions_in_thread!( @@ -1141,7 +1153,7 @@ pub fn send_cli_focus_previous_pane_action() { initial_layout.children = vec![TiledPaneLayout::default(), TiledPaneLayout::default()]; let mut mock_screen = MockScreen::new(size); let session_metadata = mock_screen.clone_session_metadata(); - let screen_thread = mock_screen.run(Some(initial_layout)); + let screen_thread = mock_screen.run(Some(initial_layout), vec![]); let received_server_instructions = Arc::new(Mutex::new(vec![])); let server_receiver = mock_screen.server_receiver.take().unwrap(); let server_instruction = log_actions_in_thread!( @@ -1174,7 +1186,7 @@ pub fn send_cli_move_focus_pane_action() { initial_layout.children = vec![TiledPaneLayout::default(), TiledPaneLayout::default()]; let mut mock_screen = MockScreen::new(size); let session_metadata = mock_screen.clone_session_metadata(); - let screen_thread = mock_screen.run(Some(initial_layout)); + let screen_thread = mock_screen.run(Some(initial_layout), vec![]); let received_server_instructions = Arc::new(Mutex::new(vec![])); let server_receiver = mock_screen.server_receiver.take().unwrap(); let server_instruction = log_actions_in_thread!( @@ -1209,7 +1221,7 @@ pub fn send_cli_move_focus_or_tab_pane_action() { initial_layout.children = vec![TiledPaneLayout::default(), TiledPaneLayout::default()]; let mut mock_screen = MockScreen::new(size); let session_metadata = mock_screen.clone_session_metadata(); - let screen_thread = mock_screen.run(Some(initial_layout)); + let screen_thread = mock_screen.run(Some(initial_layout), vec![]); let received_server_instructions = Arc::new(Mutex::new(vec![])); let server_receiver = mock_screen.server_receiver.take().unwrap(); let server_instruction = log_actions_in_thread!( @@ -1244,7 +1256,7 @@ pub fn send_cli_move_pane_action() { initial_layout.children = vec![TiledPaneLayout::default(), TiledPaneLayout::default()]; let mut mock_screen = MockScreen::new(size); let session_metadata = mock_screen.clone_session_metadata(); - let screen_thread = mock_screen.run(Some(initial_layout)); + let screen_thread = mock_screen.run(Some(initial_layout), vec![]); let received_server_instructions = Arc::new(Mutex::new(vec![])); let server_receiver = mock_screen.server_receiver.take().unwrap(); let server_instruction = log_actions_in_thread!( @@ -1278,7 +1290,7 @@ pub fn send_cli_dump_screen_action() { initial_layout.children = vec![TiledPaneLayout::default(), TiledPaneLayout::default()]; let mut mock_screen = MockScreen::new(size); let session_metadata = mock_screen.clone_session_metadata(); - let screen_thread = mock_screen.run(Some(initial_layout)); + let screen_thread = mock_screen.run(Some(initial_layout), vec![]); let received_server_instructions = Arc::new(Mutex::new(vec![])); let server_receiver = mock_screen.server_receiver.take().unwrap(); let server_thread = log_actions_in_thread!( @@ -1312,7 +1324,7 @@ pub fn send_cli_edit_scrollback_action() { initial_layout.children = vec![TiledPaneLayout::default(), TiledPaneLayout::default()]; let mut mock_screen = MockScreen::new(size); let session_metadata = mock_screen.clone_session_metadata(); - let screen_thread = mock_screen.run(Some(initial_layout)); + let screen_thread = mock_screen.run(Some(initial_layout), vec![]); let received_pty_instructions = Arc::new(Mutex::new(vec![])); let pty_receiver = mock_screen.pty_receiver.take().unwrap(); let pty_thread = log_actions_in_thread!( @@ -1360,7 +1372,7 @@ pub fn send_cli_scroll_up_action() { initial_layout.children = vec![TiledPaneLayout::default(), TiledPaneLayout::default()]; let mut mock_screen = MockScreen::new(size); let session_metadata = mock_screen.clone_session_metadata(); - let screen_thread = mock_screen.run(Some(initial_layout)); + let screen_thread = mock_screen.run(Some(initial_layout), vec![]); let received_server_instructions = Arc::new(Mutex::new(vec![])); let server_receiver = mock_screen.server_receiver.take().unwrap(); let server_instruction = log_actions_in_thread!( @@ -1404,7 +1416,7 @@ pub fn send_cli_scroll_down_action() { initial_layout.children = vec![TiledPaneLayout::default(), TiledPaneLayout::default()]; let mut mock_screen = MockScreen::new(size); let session_metadata = mock_screen.clone_session_metadata(); - let screen_thread = mock_screen.run(Some(initial_layout)); + let screen_thread = mock_screen.run(Some(initial_layout), vec![]); let received_server_instructions = Arc::new(Mutex::new(vec![])); let server_receiver = mock_screen.server_receiver.take().unwrap(); let server_instruction = log_actions_in_thread!( @@ -1454,7 +1466,7 @@ pub fn send_cli_scroll_to_bottom_action() { initial_layout.children = vec![TiledPaneLayout::default(), TiledPaneLayout::default()]; let mut mock_screen = MockScreen::new(size); let session_metadata = mock_screen.clone_session_metadata(); - let screen_thread = mock_screen.run(Some(initial_layout)); + let screen_thread = mock_screen.run(Some(initial_layout), vec![]); let received_server_instructions = Arc::new(Mutex::new(vec![])); let server_receiver = mock_screen.server_receiver.take().unwrap(); let server_instruction = log_actions_in_thread!( @@ -1507,7 +1519,7 @@ pub fn send_cli_scroll_to_top_action() { initial_layout.children = vec![TiledPaneLayout::default(), TiledPaneLayout::default()]; let mut mock_screen = MockScreen::new(size); let session_metadata = mock_screen.clone_session_metadata(); - let screen_thread = mock_screen.run(Some(initial_layout)); + let screen_thread = mock_screen.run(Some(initial_layout), vec![]); let received_server_instructions = Arc::new(Mutex::new(vec![])); let server_receiver = mock_screen.server_receiver.take().unwrap(); let server_instruction = log_actions_in_thread!( @@ -1549,7 +1561,7 @@ pub fn send_cli_page_scroll_up_action() { initial_layout.children = vec![TiledPaneLayout::default(), TiledPaneLayout::default()]; let mut mock_screen = MockScreen::new(size); let session_metadata = mock_screen.clone_session_metadata(); - let screen_thread = mock_screen.run(Some(initial_layout)); + let screen_thread = mock_screen.run(Some(initial_layout), vec![]); let received_server_instructions = Arc::new(Mutex::new(vec![])); let server_receiver = mock_screen.server_receiver.take().unwrap(); let server_instruction = log_actions_in_thread!( @@ -1590,7 +1602,7 @@ pub fn send_cli_page_scroll_down_action() { initial_layout.children = vec![TiledPaneLayout::default(), TiledPaneLayout::default()]; let mut mock_screen = MockScreen::new(size); let session_metadata = mock_screen.clone_session_metadata(); - let screen_thread = mock_screen.run(Some(initial_layout)); + let screen_thread = mock_screen.run(Some(initial_layout), vec![]); let received_server_instructions = Arc::new(Mutex::new(vec![])); let server_receiver = mock_screen.server_receiver.take().unwrap(); let server_instruction = log_actions_in_thread!( @@ -1638,7 +1650,7 @@ pub fn send_cli_half_page_scroll_up_action() { initial_layout.children = vec![TiledPaneLayout::default(), TiledPaneLayout::default()]; let mut mock_screen = MockScreen::new(size); let session_metadata = mock_screen.clone_session_metadata(); - let screen_thread = mock_screen.run(Some(initial_layout)); + let screen_thread = mock_screen.run(Some(initial_layout), vec![]); let received_server_instructions = Arc::new(Mutex::new(vec![])); let server_receiver = mock_screen.server_receiver.take().unwrap(); let server_instruction = log_actions_in_thread!( @@ -1679,7 +1691,7 @@ pub fn send_cli_half_page_scroll_down_action() { initial_layout.children = vec![TiledPaneLayout::default(), TiledPaneLayout::default()]; let mut mock_screen = MockScreen::new(size); let session_metadata = mock_screen.clone_session_metadata(); - let screen_thread = mock_screen.run(Some(initial_layout)); + let screen_thread = mock_screen.run(Some(initial_layout), vec![]); let received_server_instructions = Arc::new(Mutex::new(vec![])); let server_receiver = mock_screen.server_receiver.take().unwrap(); let server_instruction = log_actions_in_thread!( @@ -1735,7 +1747,7 @@ pub fn send_cli_toggle_full_screen_action() { initial_layout.children = vec![TiledPaneLayout::default(), TiledPaneLayout::default()]; let mut mock_screen = MockScreen::new(size); let session_metadata = mock_screen.clone_session_metadata(); - let screen_thread = mock_screen.run(Some(initial_layout)); + let screen_thread = mock_screen.run(Some(initial_layout), vec![]); let received_server_instructions = Arc::new(Mutex::new(vec![])); let server_receiver = mock_screen.server_receiver.take().unwrap(); let server_instruction = log_actions_in_thread!( @@ -1767,7 +1779,7 @@ pub fn send_cli_toggle_pane_frames_action() { initial_layout.children = vec![TiledPaneLayout::default(), TiledPaneLayout::default()]; let mut mock_screen = MockScreen::new(size); let session_metadata = mock_screen.clone_session_metadata(); - let screen_thread = mock_screen.run(Some(initial_layout)); + let screen_thread = mock_screen.run(Some(initial_layout), vec![]); let received_server_instructions = Arc::new(Mutex::new(vec![])); let server_receiver = mock_screen.server_receiver.take().unwrap(); let server_instruction = log_actions_in_thread!( @@ -1803,7 +1815,7 @@ pub fn send_cli_toggle_active_tab_sync_action() { let mut initial_layout = TiledPaneLayout::default(); initial_layout.children_split_direction = SplitDirection::Vertical; initial_layout.children = vec![TiledPaneLayout::default(), TiledPaneLayout::default()]; - let screen_thread = mock_screen.run(Some(initial_layout)); + let screen_thread = mock_screen.run(Some(initial_layout), vec![]); let received_pty_instructions = Arc::new(Mutex::new(vec![])); let pty_writer_thread = log_actions_in_thread!( received_pty_instructions, @@ -1838,7 +1850,7 @@ pub fn send_cli_new_pane_action_with_default_parameters() { let mut initial_layout = TiledPaneLayout::default(); initial_layout.children_split_direction = SplitDirection::Vertical; initial_layout.children = vec![TiledPaneLayout::default(), TiledPaneLayout::default()]; - let screen_thread = mock_screen.run(Some(initial_layout)); + let screen_thread = mock_screen.run(Some(initial_layout), vec![]); let received_pty_instructions = Arc::new(Mutex::new(vec![])); let pty_thread = log_actions_in_thread!( received_pty_instructions, @@ -1875,7 +1887,7 @@ pub fn send_cli_new_pane_action_with_split_direction() { let mut initial_layout = TiledPaneLayout::default(); initial_layout.children_split_direction = SplitDirection::Vertical; initial_layout.children = vec![TiledPaneLayout::default(), TiledPaneLayout::default()]; - let screen_thread = mock_screen.run(Some(initial_layout)); + let screen_thread = mock_screen.run(Some(initial_layout), vec![]); let received_pty_instructions = Arc::new(Mutex::new(vec![])); let pty_thread = log_actions_in_thread!( received_pty_instructions, @@ -1912,7 +1924,7 @@ pub fn send_cli_new_pane_action_with_command_and_cwd() { let mut initial_layout = TiledPaneLayout::default(); initial_layout.children_split_direction = SplitDirection::Vertical; initial_layout.children = vec![TiledPaneLayout::default(), TiledPaneLayout::default()]; - let screen_thread = mock_screen.run(Some(initial_layout)); + let screen_thread = mock_screen.run(Some(initial_layout), vec![]); let received_pty_instructions = Arc::new(Mutex::new(vec![])); let pty_thread = log_actions_in_thread!( received_pty_instructions, @@ -1949,7 +1961,7 @@ pub fn send_cli_edit_action_with_default_parameters() { let mut initial_layout = TiledPaneLayout::default(); initial_layout.children_split_direction = SplitDirection::Vertical; initial_layout.children = vec![TiledPaneLayout::default(), TiledPaneLayout::default()]; - let screen_thread = mock_screen.run(Some(initial_layout)); + let screen_thread = mock_screen.run(Some(initial_layout), vec![]); let received_pty_instructions = Arc::new(Mutex::new(vec![])); let pty_thread = log_actions_in_thread!( received_pty_instructions, @@ -1982,7 +1994,7 @@ pub fn send_cli_edit_action_with_line_number() { let mut initial_layout = TiledPaneLayout::default(); initial_layout.children_split_direction = SplitDirection::Vertical; initial_layout.children = vec![TiledPaneLayout::default(), TiledPaneLayout::default()]; - let screen_thread = mock_screen.run(Some(initial_layout)); + let screen_thread = mock_screen.run(Some(initial_layout), vec![]); let received_pty_instructions = Arc::new(Mutex::new(vec![])); let pty_thread = log_actions_in_thread!( received_pty_instructions, @@ -2015,7 +2027,7 @@ pub fn send_cli_edit_action_with_split_direction() { let mut initial_layout = TiledPaneLayout::default(); initial_layout.children_split_direction = SplitDirection::Vertical; initial_layout.children = vec![TiledPaneLayout::default(), TiledPaneLayout::default()]; - let screen_thread = mock_screen.run(Some(initial_layout)); + let screen_thread = mock_screen.run(Some(initial_layout), vec![]); let received_pty_instructions = Arc::new(Mutex::new(vec![])); let pty_thread = log_actions_in_thread!( received_pty_instructions, @@ -2047,7 +2059,7 @@ pub fn send_cli_switch_mode_action() { let mut initial_layout = TiledPaneLayout::default(); initial_layout.children_split_direction = SplitDirection::Vertical; initial_layout.children = vec![TiledPaneLayout::default(), TiledPaneLayout::default()]; - let screen_thread = mock_screen.run(Some(initial_layout)); + let screen_thread = mock_screen.run(Some(initial_layout), vec![]); let cli_switch_mode = CliAction::SwitchMode { input_mode: InputMode::Locked, }; @@ -2073,7 +2085,7 @@ pub fn send_cli_toggle_pane_embed_or_float() { initial_layout.children = vec![TiledPaneLayout::default(), TiledPaneLayout::default()]; let mut mock_screen = MockScreen::new(size); let session_metadata = mock_screen.clone_session_metadata(); - let screen_thread = mock_screen.run(Some(initial_layout)); + let screen_thread = mock_screen.run(Some(initial_layout), vec![]); let received_server_instructions = Arc::new(Mutex::new(vec![])); let server_receiver = mock_screen.server_receiver.take().unwrap(); let server_instruction = log_actions_in_thread!( @@ -2117,7 +2129,7 @@ pub fn send_cli_toggle_floating_panes() { initial_layout.children = vec![TiledPaneLayout::default(), TiledPaneLayout::default()]; let mut mock_screen = MockScreen::new(size); let session_metadata = mock_screen.clone_session_metadata(); - let screen_thread = mock_screen.run(Some(initial_layout)); + let screen_thread = mock_screen.run(Some(initial_layout), vec![]); let received_server_instructions = Arc::new(Mutex::new(vec![])); let server_receiver = mock_screen.server_receiver.take().unwrap(); let server_instruction = log_actions_in_thread!( @@ -2157,7 +2169,7 @@ pub fn send_cli_close_pane_action() { initial_layout.children = vec![TiledPaneLayout::default(), TiledPaneLayout::default()]; let mut mock_screen = MockScreen::new(size); let session_metadata = mock_screen.clone_session_metadata(); - let screen_thread = mock_screen.run(Some(initial_layout)); + let screen_thread = mock_screen.run(Some(initial_layout), vec![]); let received_server_instructions = Arc::new(Mutex::new(vec![])); let server_receiver = mock_screen.server_receiver.take().unwrap(); let server_instruction = log_actions_in_thread!( @@ -2189,7 +2201,7 @@ pub fn send_cli_new_tab_action_default_params() { initial_layout.children = vec![TiledPaneLayout::default(), TiledPaneLayout::default()]; let mut mock_screen = MockScreen::new(size); let session_metadata = mock_screen.clone_session_metadata(); - let screen_thread = mock_screen.run(Some(initial_layout)); + let screen_thread = mock_screen.run(Some(initial_layout), vec![]); let received_plugin_instructions = Arc::new(Mutex::new(vec![])); let plugin_receiver = mock_screen.plugin_receiver.take().unwrap(); let plugin_thread = log_actions_in_thread!( @@ -2226,7 +2238,7 @@ pub fn send_cli_new_tab_action_with_name_and_layout() { initial_layout.children = vec![TiledPaneLayout::default(), TiledPaneLayout::default()]; let mut mock_screen = MockScreen::new(size); let session_metadata = mock_screen.clone_session_metadata(); - let screen_thread = mock_screen.run(Some(initial_layout)); + let screen_thread = mock_screen.run(Some(initial_layout), vec![]); let received_plugin_instructions = Arc::new(Mutex::new(vec![])); let plugin_receiver = mock_screen.plugin_receiver.take().unwrap(); let plugin_thread = log_actions_in_thread!( @@ -2276,7 +2288,7 @@ pub fn send_cli_next_tab_action() { let mut mock_screen = MockScreen::new(size); mock_screen.new_tab(second_tab_layout); let session_metadata = mock_screen.clone_session_metadata(); - let screen_thread = mock_screen.run(Some(initial_layout)); + let screen_thread = mock_screen.run(Some(initial_layout), vec![]); let received_server_instructions = Arc::new(Mutex::new(vec![])); let server_receiver = mock_screen.server_receiver.take().unwrap(); let server_thread = log_actions_in_thread!( @@ -2312,7 +2324,7 @@ pub fn send_cli_previous_tab_action() { let mut mock_screen = MockScreen::new(size); mock_screen.new_tab(second_tab_layout); let session_metadata = mock_screen.clone_session_metadata(); - let screen_thread = mock_screen.run(Some(initial_layout)); + let screen_thread = mock_screen.run(Some(initial_layout), vec![]); let received_server_instructions = Arc::new(Mutex::new(vec![])); let server_receiver = mock_screen.server_receiver.take().unwrap(); let server_thread = log_actions_in_thread!( @@ -2348,7 +2360,7 @@ pub fn send_cli_goto_tab_action() { let mut mock_screen = MockScreen::new(size); mock_screen.new_tab(second_tab_layout); let session_metadata = mock_screen.clone_session_metadata(); - let screen_thread = mock_screen.run(Some(initial_layout)); + let screen_thread = mock_screen.run(Some(initial_layout), vec![]); let received_server_instructions = Arc::new(Mutex::new(vec![])); let server_receiver = mock_screen.server_receiver.take().unwrap(); let server_thread = log_actions_in_thread!( @@ -2384,7 +2396,7 @@ pub fn send_cli_close_tab_action() { let mut mock_screen = MockScreen::new(size); mock_screen.new_tab(second_tab_layout); let session_metadata = mock_screen.clone_session_metadata(); - let screen_thread = mock_screen.run(Some(initial_layout)); + let screen_thread = mock_screen.run(Some(initial_layout), vec![]); let received_server_instructions = Arc::new(Mutex::new(vec![])); let server_receiver = mock_screen.server_receiver.take().unwrap(); let server_thread = log_actions_in_thread!( @@ -2420,7 +2432,7 @@ pub fn send_cli_rename_tab() { let mut mock_screen = MockScreen::new(size); mock_screen.new_tab(second_tab_layout); let session_metadata = mock_screen.clone_session_metadata(); - let screen_thread = mock_screen.run(Some(initial_layout)); + let screen_thread = mock_screen.run(Some(initial_layout), vec![]); let received_plugin_instructions = Arc::new(Mutex::new(vec![])); let plugin_receiver = mock_screen.plugin_receiver.take().unwrap(); let plugin_thread = log_actions_in_thread!( @@ -2465,7 +2477,7 @@ pub fn send_cli_undo_rename_tab() { let mut mock_screen = MockScreen::new(size); mock_screen.new_tab(second_tab_layout); let session_metadata = mock_screen.clone_session_metadata(); - let screen_thread = mock_screen.run(Some(initial_layout)); + let screen_thread = mock_screen.run(Some(initial_layout), vec![]); let received_plugin_instructions = Arc::new(Mutex::new(vec![])); let plugin_receiver = mock_screen.plugin_receiver.take().unwrap(); let plugin_thread = log_actions_in_thread!( @@ -2509,7 +2521,7 @@ pub fn send_cli_query_tab_names_action() { let mut mock_screen = MockScreen::new(size); mock_screen.new_tab(TiledPaneLayout::default()); let session_metadata = mock_screen.clone_session_metadata(); - let screen_thread = mock_screen.run(Some(TiledPaneLayout::default())); + let screen_thread = mock_screen.run(Some(TiledPaneLayout::default()), vec![]); let received_server_instructions = Arc::new(Mutex::new(vec![])); let server_receiver = mock_screen.server_receiver.take().unwrap(); let server_thread = log_actions_in_thread!( @@ -2543,7 +2555,7 @@ pub fn send_cli_launch_or_focus_plugin_action() { let mut mock_screen = MockScreen::new(size); let plugin_receiver = mock_screen.plugin_receiver.take().unwrap(); let session_metadata = mock_screen.clone_session_metadata(); - let screen_thread = mock_screen.run(None); + let screen_thread = mock_screen.run(None, vec![]); let received_plugin_instructions = Arc::new(Mutex::new(vec![])); let plugin_thread = log_actions_in_thread!( received_plugin_instructions, @@ -2593,7 +2605,7 @@ pub fn send_cli_launch_or_focus_plugin_action_when_plugin_is_already_loaded() { }; initial_layout.children_split_direction = SplitDirection::Vertical; initial_layout.children = vec![TiledPaneLayout::default(), existing_plugin_pane]; - let screen_thread = mock_screen.run(Some(initial_layout)); + let screen_thread = mock_screen.run(Some(initial_layout), vec![]); let received_plugin_instructions = Arc::new(Mutex::new(vec![])); let plugin_thread = log_actions_in_thread!( received_plugin_instructions, @@ -2653,7 +2665,7 @@ pub fn screen_can_suppress_pane() { initial_layout.children_split_direction = SplitDirection::Vertical; initial_layout.children = vec![TiledPaneLayout::default(), TiledPaneLayout::default()]; let mut mock_screen = MockScreen::new(size); - let screen_thread = mock_screen.run(Some(initial_layout)); + let screen_thread = mock_screen.run(Some(initial_layout), vec![]); let received_server_instructions = Arc::new(Mutex::new(vec![])); let server_receiver = mock_screen.server_receiver.take().unwrap(); let server_thread = log_actions_in_thread!( @@ -2677,3 +2689,403 @@ pub fn screen_can_suppress_pane() { } assert_snapshot!(format!("{}", snapshot_count)); } + +#[test] +pub fn screen_can_break_pane_to_a_new_tab() { + let size = Size { cols: 80, rows: 20 }; + let mut initial_layout = TiledPaneLayout::default(); + let mut pane_to_break_free = TiledPaneLayout::default(); + pane_to_break_free.name = Some("pane_to_break_free".to_owned()); + let mut pane_to_stay = TiledPaneLayout::default(); + pane_to_stay.name = Some("pane_to_stay".to_owned()); + initial_layout.children_split_direction = SplitDirection::Vertical; + initial_layout.children = vec![pane_to_break_free, pane_to_stay]; + let mut mock_screen = MockScreen::new(size); + let screen_thread = mock_screen.run(Some(initial_layout), vec![]); + let received_server_instructions = Arc::new(Mutex::new(vec![])); + let server_receiver = mock_screen.server_receiver.take().unwrap(); + let server_thread = log_actions_in_thread!( + received_server_instructions, + ServerInstruction::KillSession, + server_receiver + ); + + let _ = mock_screen.to_screen.send(ScreenInstruction::BreakPane( + Box::new(Layout::default()), + Default::default(), + 1, + )); + std::thread::sleep(std::time::Duration::from_millis(100)); + // we send ApplyLayout, because in prod this is eventually received after the message traverses + // through the plugin and pty threads (to open extra stuff we need in the layout, eg. the + // default plugins) + let _ = mock_screen.to_screen.send(ScreenInstruction::ApplyLayout( + TiledPaneLayout::default(), + vec![], // floating_panes_layout + Default::default(), + vec![], // floating panes ids + Default::default(), + 1, + 1, + )); + std::thread::sleep(std::time::Duration::from_millis(100)); + // move back to make sure the other pane is in the previous tab + let _ = mock_screen + .to_screen + .send(ScreenInstruction::MoveFocusLeftOrPreviousTab(1)); + std::thread::sleep(std::time::Duration::from_millis(100)); + // move forward to make sure the broken pane is in the previous tab + let _ = mock_screen + .to_screen + .send(ScreenInstruction::MoveFocusRightOrNextTab(1)); + std::thread::sleep(std::time::Duration::from_millis(100)); + + mock_screen.teardown(vec![server_thread, screen_thread]); + + let snapshots = take_snapshots_and_cursor_coordinates_from_render_events( + received_server_instructions.lock().unwrap().iter(), + size, + ); + let snapshot_count = snapshots.len(); + for (_cursor_coordinates, snapshot) in snapshots { + assert_snapshot!(format!("{}", snapshot)); + } + assert_snapshot!(format!("{}", snapshot_count)); +} + +#[test] +pub fn screen_cannot_break_last_selectable_pane_to_a_new_tab() { + let size = Size { cols: 80, rows: 20 }; + let initial_layout = TiledPaneLayout::default(); + let mut mock_screen = MockScreen::new(size); + let screen_thread = mock_screen.run(Some(initial_layout), vec![]); + let received_server_instructions = Arc::new(Mutex::new(vec![])); + let server_receiver = mock_screen.server_receiver.take().unwrap(); + let server_thread = log_actions_in_thread!( + received_server_instructions, + ServerInstruction::KillSession, + server_receiver + ); + + let _ = mock_screen.to_screen.send(ScreenInstruction::BreakPane( + Box::new(Layout::default()), + Default::default(), + 1, + )); + std::thread::sleep(std::time::Duration::from_millis(100)); + + mock_screen.teardown(vec![server_thread, screen_thread]); + + let snapshots = take_snapshots_and_cursor_coordinates_from_render_events( + received_server_instructions.lock().unwrap().iter(), + size, + ); + let snapshot_count = snapshots.len(); + for (_cursor_coordinates, snapshot) in snapshots { + assert_snapshot!(format!("{}", snapshot)); + } + assert_snapshot!(format!("{}", snapshot_count)); +} + +#[test] +pub fn screen_can_break_floating_pane_to_a_new_tab() { + let size = Size { cols: 80, rows: 20 }; + let mut initial_layout = TiledPaneLayout::default(); + let mut pane_to_break_free = TiledPaneLayout::default(); + pane_to_break_free.name = Some("tiled_pane".to_owned()); + let mut floating_pane = FloatingPaneLayout::default(); + floating_pane.name = Some("floating_pane_to_eject".to_owned()); + let mut floating_panes_layout = vec![floating_pane]; + initial_layout.children_split_direction = SplitDirection::Vertical; + initial_layout.children = vec![pane_to_break_free]; + let mut mock_screen = MockScreen::new(size); + let screen_thread = mock_screen.run(Some(initial_layout), floating_panes_layout.clone()); + let received_server_instructions = Arc::new(Mutex::new(vec![])); + let server_receiver = mock_screen.server_receiver.take().unwrap(); + let server_thread = log_actions_in_thread!( + received_server_instructions, + ServerInstruction::KillSession, + server_receiver + ); + + let _ = mock_screen.to_screen.send(ScreenInstruction::BreakPane( + Box::new(Layout::default()), + Default::default(), + 1, + )); + std::thread::sleep(std::time::Duration::from_millis(100)); + // we send ApplyLayout, because in prod this is eventually received after the message traverses + // through the plugin and pty threads (to open extra stuff we need in the layout, eg. the + // default plugins) + floating_panes_layout.get_mut(0).unwrap().already_running = true; + let _ = mock_screen.to_screen.send(ScreenInstruction::ApplyLayout( + TiledPaneLayout::default(), + floating_panes_layout, + vec![(1, None)], // tiled pane ids - send these because one needs to be created under the + // ejected floating pane, lest the tab be closed as having no tiled panes + // (this happens in prod in the pty thread) + vec![], // floating panes ids + Default::default(), + 1, + 1, + )); + std::thread::sleep(std::time::Duration::from_millis(100)); + // move back to make sure the other pane is in the previous tab + let _ = mock_screen + .to_screen + .send(ScreenInstruction::MoveFocusLeftOrPreviousTab(1)); + std::thread::sleep(std::time::Duration::from_millis(100)); + // move forward to make sure the broken pane is in the previous tab + let _ = mock_screen + .to_screen + .send(ScreenInstruction::MoveFocusRightOrNextTab(1)); + std::thread::sleep(std::time::Duration::from_millis(100)); + + mock_screen.teardown(vec![server_thread, screen_thread]); + + let snapshots = take_snapshots_and_cursor_coordinates_from_render_events( + received_server_instructions.lock().unwrap().iter(), + size, + ); + let snapshot_count = snapshots.len(); + for (_cursor_coordinates, snapshot) in snapshots { + assert_snapshot!(format!("{}", snapshot)); + } + assert_snapshot!(format!("{}", snapshot_count)); +} + +#[test] +pub fn screen_can_break_plugin_pane_to_a_new_tab() { + let size = Size { cols: 80, rows: 20 }; + let mut initial_layout = TiledPaneLayout::default(); + let mut pane_to_break_free = TiledPaneLayout::default(); + pane_to_break_free.name = Some("plugin_pane_to_break_free".to_owned()); + pane_to_break_free.run = Some(Run::Plugin(RunPlugin { + _allow_exec_host_cmd: false, + location: RunPluginLocation::File(PathBuf::from("/path/to/fake/plugin")), + configuration: Default::default(), + })); + let mut pane_to_stay = TiledPaneLayout::default(); + pane_to_stay.name = Some("pane_to_stay".to_owned()); + initial_layout.children_split_direction = SplitDirection::Vertical; + initial_layout.children = vec![pane_to_break_free, pane_to_stay]; + let mut mock_screen = MockScreen::new(size); + let screen_thread = mock_screen.run(Some(initial_layout), vec![]); + let received_server_instructions = Arc::new(Mutex::new(vec![])); + let server_receiver = mock_screen.server_receiver.take().unwrap(); + let server_thread = log_actions_in_thread!( + received_server_instructions, + ServerInstruction::KillSession, + server_receiver + ); + + let _ = mock_screen.to_screen.send(ScreenInstruction::BreakPane( + Box::new(Layout::default()), + Default::default(), + 1, + )); + std::thread::sleep(std::time::Duration::from_millis(100)); + // we send ApplyLayout, because in prod this is eventually received after the message traverses + // through the plugin and pty threads (to open extra stuff we need in the layout, eg. the + // default plugins) + let _ = mock_screen.to_screen.send(ScreenInstruction::ApplyLayout( + TiledPaneLayout::default(), + vec![], // floating_panes_layout + Default::default(), + vec![], // floating panes ids + Default::default(), + 1, + 1, + )); + std::thread::sleep(std::time::Duration::from_millis(100)); + // move back to make sure the other pane is in the previous tab + let _ = mock_screen + .to_screen + .send(ScreenInstruction::MoveFocusLeftOrPreviousTab(1)); + std::thread::sleep(std::time::Duration::from_millis(100)); + // move forward to make sure the broken pane is in the previous tab + let _ = mock_screen + .to_screen + .send(ScreenInstruction::MoveFocusRightOrNextTab(1)); + std::thread::sleep(std::time::Duration::from_millis(100)); + + mock_screen.teardown(vec![server_thread, screen_thread]); + + let snapshots = take_snapshots_and_cursor_coordinates_from_render_events( + received_server_instructions.lock().unwrap().iter(), + size, + ); + let snapshot_count = snapshots.len(); + for (_cursor_coordinates, snapshot) in snapshots { + assert_snapshot!(format!("{}", snapshot)); + } + assert_snapshot!(format!("{}", snapshot_count)); +} + +#[test] +pub fn screen_can_break_floating_plugin_pane_to_a_new_tab() { + let size = Size { cols: 80, rows: 20 }; + let mut initial_layout = TiledPaneLayout::default(); + let mut pane_to_break_free = TiledPaneLayout::default(); + pane_to_break_free.name = Some("tiled_pane".to_owned()); + let mut floating_pane = FloatingPaneLayout::default(); + floating_pane.name = Some("floating_plugin_pane_to_eject".to_owned()); + floating_pane.run = Some(Run::Plugin(RunPlugin { + _allow_exec_host_cmd: false, + location: RunPluginLocation::File(PathBuf::from("/path/to/fake/plugin")), + configuration: Default::default(), + })); + let mut floating_panes_layout = vec![floating_pane]; + initial_layout.children_split_direction = SplitDirection::Vertical; + initial_layout.children = vec![pane_to_break_free]; + let mut mock_screen = MockScreen::new(size); + let screen_thread = mock_screen.run(Some(initial_layout), floating_panes_layout.clone()); + let received_server_instructions = Arc::new(Mutex::new(vec![])); + let server_receiver = mock_screen.server_receiver.take().unwrap(); + let server_thread = log_actions_in_thread!( + received_server_instructions, + ServerInstruction::KillSession, + server_receiver + ); + + let _ = mock_screen.to_screen.send(ScreenInstruction::BreakPane( + Box::new(Layout::default()), + Default::default(), + 1, + )); + std::thread::sleep(std::time::Duration::from_millis(100)); + // we send ApplyLayout, because in prod this is eventually received after the message traverses + // through the plugin and pty threads (to open extra stuff we need in the layout, eg. the + // default plugins) + floating_panes_layout.get_mut(0).unwrap().already_running = true; + let _ = mock_screen.to_screen.send(ScreenInstruction::ApplyLayout( + TiledPaneLayout::default(), + floating_panes_layout, + vec![(1, None)], // tiled pane ids - send these because one needs to be created under the + // ejected floating pane, lest the tab be closed as having no tiled panes + // (this happens in prod in the pty thread) + vec![], // floating panes ids + Default::default(), + 1, + 1, + )); + std::thread::sleep(std::time::Duration::from_millis(100)); + // move back to make sure the other pane is in the previous tab + let _ = mock_screen + .to_screen + .send(ScreenInstruction::MoveFocusLeftOrPreviousTab(1)); + std::thread::sleep(std::time::Duration::from_millis(100)); + // move forward to make sure the broken pane is in the previous tab + let _ = mock_screen + .to_screen + .send(ScreenInstruction::MoveFocusRightOrNextTab(1)); + std::thread::sleep(std::time::Duration::from_millis(100)); + + mock_screen.teardown(vec![server_thread, screen_thread]); + + let snapshots = take_snapshots_and_cursor_coordinates_from_render_events( + received_server_instructions.lock().unwrap().iter(), + size, + ); + let snapshot_count = snapshots.len(); + for (_cursor_coordinates, snapshot) in snapshots { + assert_snapshot!(format!("{}", snapshot)); + } + assert_snapshot!(format!("{}", snapshot_count)); +} + +#[test] +pub fn screen_can_move_pane_to_a_new_tab_right() { + let size = Size { cols: 80, rows: 20 }; + let mut initial_layout = TiledPaneLayout::default(); + let mut pane_to_break_free = TiledPaneLayout::default(); + pane_to_break_free.name = Some("pane_to_break_free".to_owned()); + let mut pane_to_stay = TiledPaneLayout::default(); + pane_to_stay.name = Some("pane_to_stay".to_owned()); + initial_layout.children_split_direction = SplitDirection::Vertical; + initial_layout.children = vec![pane_to_break_free, pane_to_stay]; + let mut mock_screen = MockScreen::new(size); + let screen_thread = mock_screen.run(Some(initial_layout), vec![]); + let received_server_instructions = Arc::new(Mutex::new(vec![])); + let server_receiver = mock_screen.server_receiver.take().unwrap(); + let server_thread = log_actions_in_thread!( + received_server_instructions, + ServerInstruction::KillSession, + server_receiver + ); + + let _ = mock_screen.to_screen.send(ScreenInstruction::BreakPane( + Box::new(Layout::default()), + Default::default(), + 1, + )); + std::thread::sleep(std::time::Duration::from_millis(100)); + let _ = mock_screen + .to_screen + .send(ScreenInstruction::MoveFocusLeftOrPreviousTab(1)); + std::thread::sleep(std::time::Duration::from_millis(100)); + let _ = mock_screen + .to_screen + .send(ScreenInstruction::BreakPaneRight(1)); + std::thread::sleep(std::time::Duration::from_millis(100)); + + mock_screen.teardown(vec![server_thread, screen_thread]); + + let snapshots = take_snapshots_and_cursor_coordinates_from_render_events( + received_server_instructions.lock().unwrap().iter(), + size, + ); + let snapshot_count = snapshots.len(); + for (_cursor_coordinates, snapshot) in snapshots { + assert_snapshot!(format!("{}", snapshot)); + } + assert_snapshot!(format!("{}", snapshot_count)); +} + +#[test] +pub fn screen_can_move_pane_to_a_new_tab_left() { + let size = Size { cols: 80, rows: 20 }; + let mut initial_layout = TiledPaneLayout::default(); + let mut pane_to_break_free = TiledPaneLayout::default(); + pane_to_break_free.name = Some("pane_to_break_free".to_owned()); + let mut pane_to_stay = TiledPaneLayout::default(); + pane_to_stay.name = Some("pane_to_stay".to_owned()); + initial_layout.children_split_direction = SplitDirection::Vertical; + initial_layout.children = vec![pane_to_break_free, pane_to_stay]; + let mut mock_screen = MockScreen::new(size); + let screen_thread = mock_screen.run(Some(initial_layout), vec![]); + let received_server_instructions = Arc::new(Mutex::new(vec![])); + let server_receiver = mock_screen.server_receiver.take().unwrap(); + let server_thread = log_actions_in_thread!( + received_server_instructions, + ServerInstruction::KillSession, + server_receiver + ); + + let _ = mock_screen.to_screen.send(ScreenInstruction::BreakPane( + Box::new(Layout::default()), + Default::default(), + 1, + )); + std::thread::sleep(std::time::Duration::from_millis(100)); + let _ = mock_screen + .to_screen + .send(ScreenInstruction::MoveFocusLeftOrPreviousTab(1)); + std::thread::sleep(std::time::Duration::from_millis(100)); + let _ = mock_screen + .to_screen + .send(ScreenInstruction::BreakPaneLeft(1)); + std::thread::sleep(std::time::Duration::from_millis(100)); + + mock_screen.teardown(vec![server_thread, screen_thread]); + + let snapshots = take_snapshots_and_cursor_coordinates_from_render_events( + received_server_instructions.lock().unwrap().iter(), + size, + ); + let snapshot_count = snapshots.len(); + for (_cursor_coordinates, snapshot) in snapshots { + assert_snapshot!(format!("{}", snapshot)); + } + assert_snapshot!(format!("{}", snapshot_count)); +} diff --git a/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_break_floating_pane_to_a_new_tab-2.snap b/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_break_floating_pane_to_a_new_tab-2.snap new file mode 100644 index 0000000000..5fa4bb26c5 --- /dev/null +++ b/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_break_floating_pane_to_a_new_tab-2.snap @@ -0,0 +1,26 @@ +--- +source: zellij-server/src/./unit/screen_tests.rs +assertion_line: 2849 +expression: "format!(\"{}\", snapshot)" +--- +00 (C): ┌ Pane #2 ─────────────────────────────────────────────────────────────────────┐ +01 (C): │ │ +02 (C): │ │ +03 (C): │ │ +04 (C): │ │ +05 (C): │ │ +06 (C): │ │ +07 (C): │ ┌ floating_pane_to_eject ──────────────┐ │ +08 (C): │ │ │ │ +09 (C): │ │ │ │ +10 (C): │ │ │ │ +11 (C): │ │ │ │ +12 (C): │ │ │ │ +13 (C): │ │ │ │ +14 (C): │ │ │ │ +15 (C): │ │ │ │ +16 (C): │ └──────────────────────────────────────┘ │ +17 (C): │ │ +18 (C): │ │ +19 (C): └──────────────────────────────────────────────────────────────────────────────┘ + diff --git a/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_break_floating_pane_to_a_new_tab-3.snap b/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_break_floating_pane_to_a_new_tab-3.snap new file mode 100644 index 0000000000..6274f758c5 --- /dev/null +++ b/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_break_floating_pane_to_a_new_tab-3.snap @@ -0,0 +1,26 @@ +--- +source: zellij-server/src/./unit/screen_tests.rs +assertion_line: 2849 +expression: "format!(\"{}\", snapshot)" +--- +00 (C): ┌ tiled_pane ──────────────────────────────────────────────────────────────────┐ +01 (C): │ │ +02 (C): │ │ +03 (C): │ │ +04 (C): │ │ +05 (C): │ │ +06 (C): │ │ +07 (C): │ │ +08 (C): │ │ +09 (C): │ │ +10 (C): │ │ +11 (C): │ │ +12 (C): │ │ +13 (C): │ │ +14 (C): │ │ +15 (C): │ │ +16 (C): │ │ +17 (C): │ │ +18 (C): │ │ +19 (C): └──────────────────────────────────────────────────────────────────────────────┘ + diff --git a/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_break_floating_pane_to_a_new_tab-4.snap b/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_break_floating_pane_to_a_new_tab-4.snap new file mode 100644 index 0000000000..5fa4bb26c5 --- /dev/null +++ b/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_break_floating_pane_to_a_new_tab-4.snap @@ -0,0 +1,26 @@ +--- +source: zellij-server/src/./unit/screen_tests.rs +assertion_line: 2849 +expression: "format!(\"{}\", snapshot)" +--- +00 (C): ┌ Pane #2 ─────────────────────────────────────────────────────────────────────┐ +01 (C): │ │ +02 (C): │ │ +03 (C): │ │ +04 (C): │ │ +05 (C): │ │ +06 (C): │ │ +07 (C): │ ┌ floating_pane_to_eject ──────────────┐ │ +08 (C): │ │ │ │ +09 (C): │ │ │ │ +10 (C): │ │ │ │ +11 (C): │ │ │ │ +12 (C): │ │ │ │ +13 (C): │ │ │ │ +14 (C): │ │ │ │ +15 (C): │ │ │ │ +16 (C): │ └──────────────────────────────────────┘ │ +17 (C): │ │ +18 (C): │ │ +19 (C): └──────────────────────────────────────────────────────────────────────────────┘ + diff --git a/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_break_floating_pane_to_a_new_tab-5.snap b/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_break_floating_pane_to_a_new_tab-5.snap new file mode 100644 index 0000000000..caa8e8714c --- /dev/null +++ b/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_break_floating_pane_to_a_new_tab-5.snap @@ -0,0 +1,6 @@ +--- +source: zellij-server/src/./unit/screen_tests.rs +assertion_line: 2851 +expression: "format!(\"{}\", snapshot_count)" +--- +4 diff --git a/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_break_floating_pane_to_a_new_tab.snap b/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_break_floating_pane_to_a_new_tab.snap new file mode 100644 index 0000000000..8460af7b0b --- /dev/null +++ b/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_break_floating_pane_to_a_new_tab.snap @@ -0,0 +1,26 @@ +--- +source: zellij-server/src/./unit/screen_tests.rs +assertion_line: 2849 +expression: "format!(\"{}\", snapshot)" +--- +00 (C): ┌ tiled_pane ──────────────────────────────────────────────────────────────────┐ +01 (C): │ │ +02 (C): │ │ +03 (C): │ │ +04 (C): │ │ +05 (C): │ ┌ floating_pane_to_eject ──────────────┐ │ +06 (C): │ │ │ │ +07 (C): │ │ │ │ +08 (C): │ │ │ │ +09 (C): │ │ │ │ +10 (C): │ │ │ │ +11 (C): │ │ │ │ +12 (C): │ │ │ │ +13 (C): │ │ │ │ +14 (C): │ └──────────────────────────────────────┘ │ +15 (C): │ │ +16 (C): │ │ +17 (C): │ │ +18 (C): │ │ +19 (C): └──────────────────────────────────────────────────────────────────────────────┘ + diff --git a/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_break_floating_plugin_pane_to_a_new_tab-2.snap b/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_break_floating_plugin_pane_to_a_new_tab-2.snap new file mode 100644 index 0000000000..85285fcf2d --- /dev/null +++ b/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_break_floating_plugin_pane_to_a_new_tab-2.snap @@ -0,0 +1,26 @@ +--- +source: zellij-server/src/./unit/screen_tests.rs +assertion_line: 2986 +expression: "format!(\"{}\", snapshot)" +--- +00 (C): ┌ tiled_pane ──────────────────────────────────────────────────────────────────┐ +01 (C): │ │ +02 (C): │ │ +03 (C): │ │ +04 (C): │ │ +05 (C): │ ┌ /path/to/fake/plugin ────────────────┐ │ +06 (C): │ │Loading /path/to/fake/plugin │ │ +07 (C): │ │ │ │ +08 (C): │ │ │ │ +09 (C): │ │ │ │ +10 (C): │ │ │ │ +11 (C): │ │ │ │ +12 (C): │ │ │ │ +13 (C): │ │ │ │ +14 (C): │ └──────────────────────────────────────┘ │ +15 (C): │ │ +16 (C): │ │ +17 (C): │ │ +18 (C): │ │ +19 (C): └──────────────────────────────────────────────────────────────────────────────┘ + diff --git a/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_break_floating_plugin_pane_to_a_new_tab-3.snap b/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_break_floating_plugin_pane_to_a_new_tab-3.snap new file mode 100644 index 0000000000..bf91ddbdfa --- /dev/null +++ b/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_break_floating_plugin_pane_to_a_new_tab-3.snap @@ -0,0 +1,26 @@ +--- +source: zellij-server/src/./unit/screen_tests.rs +assertion_line: 2986 +expression: "format!(\"{}\", snapshot)" +--- +00 (C): ┌ Pane #1 ─────────────────────────────────────────────────────────────────────┐ +01 (C): │ │ +02 (C): │ │ +03 (C): │ │ +04 (C): │ │ +05 (C): │ │ +06 (C): │ │ +07 (C): │ ┌ /path/to/fake/plugin ────────────────┐ │ +08 (C): │ │Loading /path/to/fake/plugin │ │ +09 (C): │ │ │ │ +10 (C): │ │ │ │ +11 (C): │ │ │ │ +12 (C): │ │ │ │ +13 (C): │ │ │ │ +14 (C): │ │ │ │ +15 (C): │ │ │ │ +16 (C): │ └──────────────────────────────────────┘ │ +17 (C): │ │ +18 (C): │ │ +19 (C): └──────────────────────────────────────────────────────────────────────────────┘ + diff --git a/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_break_floating_plugin_pane_to_a_new_tab-4.snap b/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_break_floating_plugin_pane_to_a_new_tab-4.snap new file mode 100644 index 0000000000..bf91ddbdfa --- /dev/null +++ b/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_break_floating_plugin_pane_to_a_new_tab-4.snap @@ -0,0 +1,26 @@ +--- +source: zellij-server/src/./unit/screen_tests.rs +assertion_line: 2986 +expression: "format!(\"{}\", snapshot)" +--- +00 (C): ┌ Pane #1 ─────────────────────────────────────────────────────────────────────┐ +01 (C): │ │ +02 (C): │ │ +03 (C): │ │ +04 (C): │ │ +05 (C): │ │ +06 (C): │ │ +07 (C): │ ┌ /path/to/fake/plugin ────────────────┐ │ +08 (C): │ │Loading /path/to/fake/plugin │ │ +09 (C): │ │ │ │ +10 (C): │ │ │ │ +11 (C): │ │ │ │ +12 (C): │ │ │ │ +13 (C): │ │ │ │ +14 (C): │ │ │ │ +15 (C): │ │ │ │ +16 (C): │ └──────────────────────────────────────┘ │ +17 (C): │ │ +18 (C): │ │ +19 (C): └──────────────────────────────────────────────────────────────────────────────┘ + diff --git a/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_break_floating_plugin_pane_to_a_new_tab-5.snap b/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_break_floating_plugin_pane_to_a_new_tab-5.snap new file mode 100644 index 0000000000..7af6aae61c --- /dev/null +++ b/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_break_floating_plugin_pane_to_a_new_tab-5.snap @@ -0,0 +1,26 @@ +--- +source: zellij-server/src/./unit/screen_tests.rs +assertion_line: 2986 +expression: "format!(\"{}\", snapshot)" +--- +00 (C): ┌ tiled_pane ──────────────────────────────────────────────────────────────────┐ +01 (C): │ │ +02 (C): │ │ +03 (C): │ │ +04 (C): │ │ +05 (C): │ │ +06 (C): │ │ +07 (C): │ │ +08 (C): │ │ +09 (C): │ │ +10 (C): │ │ +11 (C): │ │ +12 (C): │ │ +13 (C): │ │ +14 (C): │ │ +15 (C): │ │ +16 (C): │ │ +17 (C): │ │ +18 (C): │ │ +19 (C): └──────────────────────────────────────────────────────────────────────────────┘ + diff --git a/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_break_floating_plugin_pane_to_a_new_tab-6.snap b/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_break_floating_plugin_pane_to_a_new_tab-6.snap new file mode 100644 index 0000000000..bf91ddbdfa --- /dev/null +++ b/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_break_floating_plugin_pane_to_a_new_tab-6.snap @@ -0,0 +1,26 @@ +--- +source: zellij-server/src/./unit/screen_tests.rs +assertion_line: 2986 +expression: "format!(\"{}\", snapshot)" +--- +00 (C): ┌ Pane #1 ─────────────────────────────────────────────────────────────────────┐ +01 (C): │ │ +02 (C): │ │ +03 (C): │ │ +04 (C): │ │ +05 (C): │ │ +06 (C): │ │ +07 (C): │ ┌ /path/to/fake/plugin ────────────────┐ │ +08 (C): │ │Loading /path/to/fake/plugin │ │ +09 (C): │ │ │ │ +10 (C): │ │ │ │ +11 (C): │ │ │ │ +12 (C): │ │ │ │ +13 (C): │ │ │ │ +14 (C): │ │ │ │ +15 (C): │ │ │ │ +16 (C): │ └──────────────────────────────────────┘ │ +17 (C): │ │ +18 (C): │ │ +19 (C): └──────────────────────────────────────────────────────────────────────────────┘ + diff --git a/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_break_floating_plugin_pane_to_a_new_tab-7.snap b/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_break_floating_plugin_pane_to_a_new_tab-7.snap new file mode 100644 index 0000000000..bf91ddbdfa --- /dev/null +++ b/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_break_floating_plugin_pane_to_a_new_tab-7.snap @@ -0,0 +1,26 @@ +--- +source: zellij-server/src/./unit/screen_tests.rs +assertion_line: 2986 +expression: "format!(\"{}\", snapshot)" +--- +00 (C): ┌ Pane #1 ─────────────────────────────────────────────────────────────────────┐ +01 (C): │ │ +02 (C): │ │ +03 (C): │ │ +04 (C): │ │ +05 (C): │ │ +06 (C): │ │ +07 (C): │ ┌ /path/to/fake/plugin ────────────────┐ │ +08 (C): │ │Loading /path/to/fake/plugin │ │ +09 (C): │ │ │ │ +10 (C): │ │ │ │ +11 (C): │ │ │ │ +12 (C): │ │ │ │ +13 (C): │ │ │ │ +14 (C): │ │ │ │ +15 (C): │ │ │ │ +16 (C): │ └──────────────────────────────────────┘ │ +17 (C): │ │ +18 (C): │ │ +19 (C): └──────────────────────────────────────────────────────────────────────────────┘ + diff --git a/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_break_floating_plugin_pane_to_a_new_tab-8.snap b/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_break_floating_plugin_pane_to_a_new_tab-8.snap new file mode 100644 index 0000000000..5c2254e143 --- /dev/null +++ b/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_break_floating_plugin_pane_to_a_new_tab-8.snap @@ -0,0 +1,6 @@ +--- +source: zellij-server/src/./unit/screen_tests.rs +assertion_line: 2988 +expression: "format!(\"{}\", snapshot_count)" +--- +7 diff --git a/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_break_floating_plugin_pane_to_a_new_tab.snap b/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_break_floating_plugin_pane_to_a_new_tab.snap new file mode 100644 index 0000000000..85285fcf2d --- /dev/null +++ b/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_break_floating_plugin_pane_to_a_new_tab.snap @@ -0,0 +1,26 @@ +--- +source: zellij-server/src/./unit/screen_tests.rs +assertion_line: 2986 +expression: "format!(\"{}\", snapshot)" +--- +00 (C): ┌ tiled_pane ──────────────────────────────────────────────────────────────────┐ +01 (C): │ │ +02 (C): │ │ +03 (C): │ │ +04 (C): │ │ +05 (C): │ ┌ /path/to/fake/plugin ────────────────┐ │ +06 (C): │ │Loading /path/to/fake/plugin │ │ +07 (C): │ │ │ │ +08 (C): │ │ │ │ +09 (C): │ │ │ │ +10 (C): │ │ │ │ +11 (C): │ │ │ │ +12 (C): │ │ │ │ +13 (C): │ │ │ │ +14 (C): │ └──────────────────────────────────────┘ │ +15 (C): │ │ +16 (C): │ │ +17 (C): │ │ +18 (C): │ │ +19 (C): └──────────────────────────────────────────────────────────────────────────────┘ + diff --git a/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_break_pane_to_a_new_tab-2.snap b/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_break_pane_to_a_new_tab-2.snap new file mode 100644 index 0000000000..347d93d423 --- /dev/null +++ b/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_break_pane_to_a_new_tab-2.snap @@ -0,0 +1,26 @@ +--- +source: zellij-server/src/./unit/screen_tests.rs +assertion_line: 2739 +expression: "format!(\"{}\", snapshot)" +--- +00 (C): ┌ pane_to_break_free ──────────────────────────────────────────────────────────┐ +01 (C): │ │ +02 (C): │ │ +03 (C): │ │ +04 (C): │ │ +05 (C): │ │ +06 (C): │ │ +07 (C): │ │ +08 (C): │ │ +09 (C): │ │ +10 (C): │ │ +11 (C): │ │ +12 (C): │ │ +13 (C): │ │ +14 (C): │ │ +15 (C): │ │ +16 (C): │ │ +17 (C): │ │ +18 (C): │ │ +19 (C): └──────────────────────────────────────────────────────────────────────────────┘ + diff --git a/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_break_pane_to_a_new_tab-3.snap b/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_break_pane_to_a_new_tab-3.snap new file mode 100644 index 0000000000..2ee1fac443 --- /dev/null +++ b/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_break_pane_to_a_new_tab-3.snap @@ -0,0 +1,26 @@ +--- +source: zellij-server/src/./unit/screen_tests.rs +assertion_line: 2739 +expression: "format!(\"{}\", snapshot)" +--- +00 (C): ┌ pane_to_stay ────────────────────────────────────────────────────────────────┐ +01 (C): │ │ +02 (C): │ │ +03 (C): │ │ +04 (C): │ │ +05 (C): │ │ +06 (C): │ │ +07 (C): │ │ +08 (C): │ │ +09 (C): │ │ +10 (C): │ │ +11 (C): │ │ +12 (C): │ │ +13 (C): │ │ +14 (C): │ │ +15 (C): │ │ +16 (C): │ │ +17 (C): │ │ +18 (C): │ │ +19 (C): └──────────────────────────────────────────────────────────────────────────────┘ + diff --git a/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_break_pane_to_a_new_tab-4.snap b/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_break_pane_to_a_new_tab-4.snap new file mode 100644 index 0000000000..347d93d423 --- /dev/null +++ b/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_break_pane_to_a_new_tab-4.snap @@ -0,0 +1,26 @@ +--- +source: zellij-server/src/./unit/screen_tests.rs +assertion_line: 2739 +expression: "format!(\"{}\", snapshot)" +--- +00 (C): ┌ pane_to_break_free ──────────────────────────────────────────────────────────┐ +01 (C): │ │ +02 (C): │ │ +03 (C): │ │ +04 (C): │ │ +05 (C): │ │ +06 (C): │ │ +07 (C): │ │ +08 (C): │ │ +09 (C): │ │ +10 (C): │ │ +11 (C): │ │ +12 (C): │ │ +13 (C): │ │ +14 (C): │ │ +15 (C): │ │ +16 (C): │ │ +17 (C): │ │ +18 (C): │ │ +19 (C): └──────────────────────────────────────────────────────────────────────────────┘ + diff --git a/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_break_pane_to_a_new_tab-5.snap b/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_break_pane_to_a_new_tab-5.snap new file mode 100644 index 0000000000..ec0c6cfb5b --- /dev/null +++ b/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_break_pane_to_a_new_tab-5.snap @@ -0,0 +1,6 @@ +--- +source: zellij-server/src/./unit/screen_tests.rs +assertion_line: 2741 +expression: "format!(\"{}\", snapshot_count)" +--- +4 diff --git a/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_break_pane_to_a_new_tab.snap b/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_break_pane_to_a_new_tab.snap new file mode 100644 index 0000000000..765e54260b --- /dev/null +++ b/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_break_pane_to_a_new_tab.snap @@ -0,0 +1,26 @@ +--- +source: zellij-server/src/./unit/screen_tests.rs +assertion_line: 2739 +expression: "format!(\"{}\", snapshot)" +--- +00 (C): ┌ pane_to_break_free ──────────────────┐┌ pane_to_stay ────────────────────────┐ +01 (C): │ ││ │ +02 (C): │ ││ │ +03 (C): │ ││ │ +04 (C): │ ││ │ +05 (C): │ ││ │ +06 (C): │ ││ │ +07 (C): │ ││ │ +08 (C): │ ││ │ +09 (C): │ ││ │ +10 (C): │ ││ │ +11 (C): │ ││ │ +12 (C): │ ││ │ +13 (C): │ ││ │ +14 (C): │ ││ │ +15 (C): │ ││ │ +16 (C): │ ││ │ +17 (C): │ ││ │ +18 (C): │ ││ │ +19 (C): └──────────────────────────────────────┘└──────────────────────────────────────┘ + diff --git a/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_break_plugin_pane_to_a_new_tab-2.snap b/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_break_plugin_pane_to_a_new_tab-2.snap new file mode 100644 index 0000000000..bbcf4b3aca --- /dev/null +++ b/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_break_plugin_pane_to_a_new_tab-2.snap @@ -0,0 +1,26 @@ +--- +source: zellij-server/src/./unit/screen_tests.rs +assertion_line: 2914 +expression: "format!(\"{}\", snapshot)" +--- +00 (C): ┌ pane_to_stay ────────────────────────────────────────────────────────────────┐ +01 (C): │ │ +02 (C): │ │ +03 (C): │ │ +04 (C): │ │ +05 (C): │ │ +06 (C): │ │ +07 (C): │ │ +08 (C): │ │ +09 (C): │ │ +10 (C): │ │ +11 (C): │ │ +12 (C): │ │ +13 (C): │ │ +14 (C): │ │ +15 (C): │ │ +16 (C): │ │ +17 (C): │ │ +18 (C): │ │ +19 (C): └──────────────────────────────────────────────────────────────────────────────┘ + diff --git a/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_break_plugin_pane_to_a_new_tab-3.snap b/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_break_plugin_pane_to_a_new_tab-3.snap new file mode 100644 index 0000000000..e0a620f36d --- /dev/null +++ b/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_break_plugin_pane_to_a_new_tab-3.snap @@ -0,0 +1,26 @@ +--- +source: zellij-server/src/./unit/screen_tests.rs +assertion_line: 2914 +expression: "format!(\"{}\", snapshot)" +--- +00 (C): ┌ plugin_pane_to_break_free ───────────────────────────────────────────────────┐ +01 (C): │Loading /path/to/fake/plugin │ +02 (C): │ │ +03 (C): │ │ +04 (C): │ │ +05 (C): │ │ +06 (C): │ │ +07 (C): │ │ +08 (C): │ │ +09 (C): │ │ +10 (C): │ │ +11 (C): │ │ +12 (C): │ │ +13 (C): │ │ +14 (C): │ │ +15 (C): │ │ +16 (C): │ │ +17 (C): │ │ +18 (C): │ │ +19 (C): └──────────────────────────────────────────────────────────────────────────────┘ + diff --git a/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_break_plugin_pane_to_a_new_tab-4.snap b/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_break_plugin_pane_to_a_new_tab-4.snap new file mode 100644 index 0000000000..e0a620f36d --- /dev/null +++ b/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_break_plugin_pane_to_a_new_tab-4.snap @@ -0,0 +1,26 @@ +--- +source: zellij-server/src/./unit/screen_tests.rs +assertion_line: 2914 +expression: "format!(\"{}\", snapshot)" +--- +00 (C): ┌ plugin_pane_to_break_free ───────────────────────────────────────────────────┐ +01 (C): │Loading /path/to/fake/plugin │ +02 (C): │ │ +03 (C): │ │ +04 (C): │ │ +05 (C): │ │ +06 (C): │ │ +07 (C): │ │ +08 (C): │ │ +09 (C): │ │ +10 (C): │ │ +11 (C): │ │ +12 (C): │ │ +13 (C): │ │ +14 (C): │ │ +15 (C): │ │ +16 (C): │ │ +17 (C): │ │ +18 (C): │ │ +19 (C): └──────────────────────────────────────────────────────────────────────────────┘ + diff --git a/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_break_plugin_pane_to_a_new_tab-5.snap b/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_break_plugin_pane_to_a_new_tab-5.snap new file mode 100644 index 0000000000..bbcf4b3aca --- /dev/null +++ b/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_break_plugin_pane_to_a_new_tab-5.snap @@ -0,0 +1,26 @@ +--- +source: zellij-server/src/./unit/screen_tests.rs +assertion_line: 2914 +expression: "format!(\"{}\", snapshot)" +--- +00 (C): ┌ pane_to_stay ────────────────────────────────────────────────────────────────┐ +01 (C): │ │ +02 (C): │ │ +03 (C): │ │ +04 (C): │ │ +05 (C): │ │ +06 (C): │ │ +07 (C): │ │ +08 (C): │ │ +09 (C): │ │ +10 (C): │ │ +11 (C): │ │ +12 (C): │ │ +13 (C): │ │ +14 (C): │ │ +15 (C): │ │ +16 (C): │ │ +17 (C): │ │ +18 (C): │ │ +19 (C): └──────────────────────────────────────────────────────────────────────────────┘ + diff --git a/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_break_plugin_pane_to_a_new_tab-6.snap b/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_break_plugin_pane_to_a_new_tab-6.snap new file mode 100644 index 0000000000..f9b6b71759 --- /dev/null +++ b/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_break_plugin_pane_to_a_new_tab-6.snap @@ -0,0 +1,6 @@ +--- +source: zellij-server/src/./unit/screen_tests.rs +assertion_line: 2916 +expression: "format!(\"{}\", snapshot_count)" +--- +5 diff --git a/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_break_plugin_pane_to_a_new_tab.snap b/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_break_plugin_pane_to_a_new_tab.snap new file mode 100644 index 0000000000..4d4ae3f9e6 --- /dev/null +++ b/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_break_plugin_pane_to_a_new_tab.snap @@ -0,0 +1,26 @@ +--- +source: zellij-server/src/./unit/screen_tests.rs +assertion_line: 2914 +expression: "format!(\"{}\", snapshot)" +--- +00 (C): ┌ plugin_pane_to_break_free ───────────┐┌ pane_to_stay ────────────────────────┐ +01 (C): │Loading /path/to/fake/plugin ││ │ +02 (C): │ ││ │ +03 (C): │ ││ │ +04 (C): │ ││ │ +05 (C): │ ││ │ +06 (C): │ ││ │ +07 (C): │ ││ │ +08 (C): │ ││ │ +09 (C): │ ││ │ +10 (C): │ ││ │ +11 (C): │ ││ │ +12 (C): │ ││ │ +13 (C): │ ││ │ +14 (C): │ ││ │ +15 (C): │ ││ │ +16 (C): │ ││ │ +17 (C): │ ││ │ +18 (C): │ ││ │ +19 (C): └──────────────────────────────────────┘└──────────────────────────────────────┘ + diff --git a/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_move_pane_to_a_new_tab_left-2.snap b/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_move_pane_to_a_new_tab_left-2.snap new file mode 100644 index 0000000000..bb34d594c7 --- /dev/null +++ b/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_move_pane_to_a_new_tab_left-2.snap @@ -0,0 +1,26 @@ +--- +source: zellij-server/src/./unit/screen_tests.rs +assertion_line: 3079 +expression: "format!(\"{}\", snapshot)" +--- +00 (C): ┌ pane_to_break_free ──────────────────────────────────────────────────────────┐ +01 (C): │ │ +02 (C): │ │ +03 (C): │ │ +04 (C): │ │ +05 (C): │ │ +06 (C): │ │ +07 (C): │ │ +08 (C): │ │ +09 (C): │ │ +10 (C): │ │ +11 (C): │ │ +12 (C): │ │ +13 (C): │ │ +14 (C): │ │ +15 (C): │ │ +16 (C): │ │ +17 (C): │ │ +18 (C): │ │ +19 (C): └──────────────────────────────────────────────────────────────────────────────┘ + diff --git a/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_move_pane_to_a_new_tab_left-3.snap b/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_move_pane_to_a_new_tab_left-3.snap new file mode 100644 index 0000000000..bcac6ce6ce --- /dev/null +++ b/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_move_pane_to_a_new_tab_left-3.snap @@ -0,0 +1,26 @@ +--- +source: zellij-server/src/./unit/screen_tests.rs +assertion_line: 3079 +expression: "format!(\"{}\", snapshot)" +--- +00 (C): ┌ pane_to_stay ────────────────────────────────────────────────────────────────┐ +01 (C): │ │ +02 (C): │ │ +03 (C): │ │ +04 (C): │ │ +05 (C): │ │ +06 (C): │ │ +07 (C): │ │ +08 (C): │ │ +09 (C): │ │ +10 (C): │ │ +11 (C): │ │ +12 (C): │ │ +13 (C): │ │ +14 (C): │ │ +15 (C): │ │ +16 (C): │ │ +17 (C): │ │ +18 (C): │ │ +19 (C): └──────────────────────────────────────────────────────────────────────────────┘ + diff --git a/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_move_pane_to_a_new_tab_left-4.snap b/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_move_pane_to_a_new_tab_left-4.snap new file mode 100644 index 0000000000..593dd95bd6 --- /dev/null +++ b/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_move_pane_to_a_new_tab_left-4.snap @@ -0,0 +1,26 @@ +--- +source: zellij-server/src/./unit/screen_tests.rs +assertion_line: 3079 +expression: "format!(\"{}\", snapshot)" +--- +00 (C): ┌ pane_to_stay ────────────────────────┐┌ pane_to_break_free ──────────────────┐ +01 (C): │ ││ │ +02 (C): │ ││ │ +03 (C): │ ││ │ +04 (C): │ ││ │ +05 (C): │ ││ │ +06 (C): │ ││ │ +07 (C): │ ││ │ +08 (C): │ ││ │ +09 (C): │ ││ │ +10 (C): │ ││ │ +11 (C): │ ││ │ +12 (C): │ ││ │ +13 (C): │ ││ │ +14 (C): │ ││ │ +15 (C): │ ││ │ +16 (C): │ ││ │ +17 (C): │ ││ │ +18 (C): │ ││ │ +19 (C): └──────────────────────────────────────┘└──────────────────────────────────────┘ + diff --git a/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_move_pane_to_a_new_tab_left-5.snap b/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_move_pane_to_a_new_tab_left-5.snap new file mode 100644 index 0000000000..53aa1b2c03 --- /dev/null +++ b/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_move_pane_to_a_new_tab_left-5.snap @@ -0,0 +1,6 @@ +--- +source: zellij-server/src/./unit/screen_tests.rs +assertion_line: 3081 +expression: "format!(\"{}\", snapshot_count)" +--- +4 diff --git a/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_move_pane_to_a_new_tab_left.snap b/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_move_pane_to_a_new_tab_left.snap new file mode 100644 index 0000000000..262029b40e --- /dev/null +++ b/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_move_pane_to_a_new_tab_left.snap @@ -0,0 +1,26 @@ +--- +source: zellij-server/src/./unit/screen_tests.rs +assertion_line: 3079 +expression: "format!(\"{}\", snapshot)" +--- +00 (C): ┌ pane_to_break_free ──────────────────┐┌ pane_to_stay ────────────────────────┐ +01 (C): │ ││ │ +02 (C): │ ││ │ +03 (C): │ ││ │ +04 (C): │ ││ │ +05 (C): │ ││ │ +06 (C): │ ││ │ +07 (C): │ ││ │ +08 (C): │ ││ │ +09 (C): │ ││ │ +10 (C): │ ││ │ +11 (C): │ ││ │ +12 (C): │ ││ │ +13 (C): │ ││ │ +14 (C): │ ││ │ +15 (C): │ ││ │ +16 (C): │ ││ │ +17 (C): │ ││ │ +18 (C): │ ││ │ +19 (C): └──────────────────────────────────────┘└──────────────────────────────────────┘ + diff --git a/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_move_pane_to_a_new_tab_right-2.snap b/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_move_pane_to_a_new_tab_right-2.snap new file mode 100644 index 0000000000..32f3248e8a --- /dev/null +++ b/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_move_pane_to_a_new_tab_right-2.snap @@ -0,0 +1,26 @@ +--- +source: zellij-server/src/./unit/screen_tests.rs +assertion_line: 3032 +expression: "format!(\"{}\", snapshot)" +--- +00 (C): ┌ pane_to_break_free ──────────────────────────────────────────────────────────┐ +01 (C): │ │ +02 (C): │ │ +03 (C): │ │ +04 (C): │ │ +05 (C): │ │ +06 (C): │ │ +07 (C): │ │ +08 (C): │ │ +09 (C): │ │ +10 (C): │ │ +11 (C): │ │ +12 (C): │ │ +13 (C): │ │ +14 (C): │ │ +15 (C): │ │ +16 (C): │ │ +17 (C): │ │ +18 (C): │ │ +19 (C): └──────────────────────────────────────────────────────────────────────────────┘ + diff --git a/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_move_pane_to_a_new_tab_right-3.snap b/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_move_pane_to_a_new_tab_right-3.snap new file mode 100644 index 0000000000..d1f54bfe96 --- /dev/null +++ b/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_move_pane_to_a_new_tab_right-3.snap @@ -0,0 +1,26 @@ +--- +source: zellij-server/src/./unit/screen_tests.rs +assertion_line: 3032 +expression: "format!(\"{}\", snapshot)" +--- +00 (C): ┌ pane_to_stay ────────────────────────────────────────────────────────────────┐ +01 (C): │ │ +02 (C): │ │ +03 (C): │ │ +04 (C): │ │ +05 (C): │ │ +06 (C): │ │ +07 (C): │ │ +08 (C): │ │ +09 (C): │ │ +10 (C): │ │ +11 (C): │ │ +12 (C): │ │ +13 (C): │ │ +14 (C): │ │ +15 (C): │ │ +16 (C): │ │ +17 (C): │ │ +18 (C): │ │ +19 (C): └──────────────────────────────────────────────────────────────────────────────┘ + diff --git a/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_move_pane_to_a_new_tab_right-4.snap b/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_move_pane_to_a_new_tab_right-4.snap new file mode 100644 index 0000000000..e9f22eb300 --- /dev/null +++ b/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_move_pane_to_a_new_tab_right-4.snap @@ -0,0 +1,26 @@ +--- +source: zellij-server/src/./unit/screen_tests.rs +assertion_line: 3032 +expression: "format!(\"{}\", snapshot)" +--- +00 (C): ┌ pane_to_stay ────────────────────────┐┌ pane_to_break_free ──────────────────┐ +01 (C): │ ││ │ +02 (C): │ ││ │ +03 (C): │ ││ │ +04 (C): │ ││ │ +05 (C): │ ││ │ +06 (C): │ ││ │ +07 (C): │ ││ │ +08 (C): │ ││ │ +09 (C): │ ││ │ +10 (C): │ ││ │ +11 (C): │ ││ │ +12 (C): │ ││ │ +13 (C): │ ││ │ +14 (C): │ ││ │ +15 (C): │ ││ │ +16 (C): │ ││ │ +17 (C): │ ││ │ +18 (C): │ ││ │ +19 (C): └──────────────────────────────────────┘└──────────────────────────────────────┘ + diff --git a/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_move_pane_to_a_new_tab_right-5.snap b/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_move_pane_to_a_new_tab_right-5.snap new file mode 100644 index 0000000000..da6e99bba9 --- /dev/null +++ b/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_move_pane_to_a_new_tab_right-5.snap @@ -0,0 +1,6 @@ +--- +source: zellij-server/src/./unit/screen_tests.rs +assertion_line: 3034 +expression: "format!(\"{}\", snapshot_count)" +--- +4 diff --git a/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_move_pane_to_a_new_tab_right.snap b/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_move_pane_to_a_new_tab_right.snap new file mode 100644 index 0000000000..31169db365 --- /dev/null +++ b/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_can_move_pane_to_a_new_tab_right.snap @@ -0,0 +1,26 @@ +--- +source: zellij-server/src/./unit/screen_tests.rs +assertion_line: 3032 +expression: "format!(\"{}\", snapshot)" +--- +00 (C): ┌ pane_to_break_free ──────────────────┐┌ pane_to_stay ────────────────────────┐ +01 (C): │ ││ │ +02 (C): │ ││ │ +03 (C): │ ││ │ +04 (C): │ ││ │ +05 (C): │ ││ │ +06 (C): │ ││ │ +07 (C): │ ││ │ +08 (C): │ ││ │ +09 (C): │ ││ │ +10 (C): │ ││ │ +11 (C): │ ││ │ +12 (C): │ ││ │ +13 (C): │ ││ │ +14 (C): │ ││ │ +15 (C): │ ││ │ +16 (C): │ ││ │ +17 (C): │ ││ │ +18 (C): │ ││ │ +19 (C): └──────────────────────────────────────┘└──────────────────────────────────────┘ + diff --git a/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_cannot_break_last_selectable_pane_to_a_new_tab-2.snap b/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_cannot_break_last_selectable_pane_to_a_new_tab-2.snap new file mode 100644 index 0000000000..93c4606dad --- /dev/null +++ b/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_cannot_break_last_selectable_pane_to_a_new_tab-2.snap @@ -0,0 +1,6 @@ +--- +source: zellij-server/src/./unit/screen_tests.rs +assertion_line: 2775 +expression: "format!(\"{}\", snapshot_count)" +--- +1 diff --git a/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_cannot_break_last_selectable_pane_to_a_new_tab.snap b/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_cannot_break_last_selectable_pane_to_a_new_tab.snap new file mode 100644 index 0000000000..ff7668a080 --- /dev/null +++ b/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__screen_cannot_break_last_selectable_pane_to_a_new_tab.snap @@ -0,0 +1,26 @@ +--- +source: zellij-server/src/./unit/screen_tests.rs +assertion_line: 2773 +expression: "format!(\"{}\", snapshot)" +--- +00 (C): ┌ Pane #1 ─────────────────────────────────────────────────────────────────────┐ +01 (C): │ │ +02 (C): │ │ +03 (C): │ │ +04 (C): │ │ +05 (C): │ │ +06 (C): │ │ +07 (C): │ │ +08 (C): │ │ +09 (C): │ │ +10 (C): │ │ +11 (C): │ │ +12 (C): │ │ +13 (C): │ │ +14 (C): │ │ +15 (C): │ │ +16 (C): │ │ +17 (C): │ │ +18 (C): │ │ +19 (C): └──────────────────────────────────────────────────────────────────────────────┘ + diff --git a/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__send_cli_new_tab_action_default_params.snap b/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__send_cli_new_tab_action_default_params.snap index a25b01b471..0943801b24 100644 --- a/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__send_cli_new_tab_action_default_params.snap +++ b/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__send_cli_new_tab_action_default_params.snap @@ -1,5 +1,6 @@ --- source: zellij-server/src/./unit/screen_tests.rs +assertion_line: 2217 expression: "format!(\"{:#?}\", new_tab_action)" --- Some( @@ -23,6 +24,7 @@ Some( children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -36,6 +38,7 @@ Some( children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -46,6 +49,7 @@ Some( children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ), [], diff --git a/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__send_cli_new_tab_action_with_name_and_layout.snap b/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__send_cli_new_tab_action_with_name_and_layout.snap index cd5300d081..257ffddf45 100644 --- a/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__send_cli_new_tab_action_with_name_and_layout.snap +++ b/zellij-server/src/unit/snapshots/zellij_server__screen__screen_tests__send_cli_new_tab_action_with_name_and_layout.snap @@ -1,6 +1,6 @@ --- source: zellij-server/src/./unit/screen_tests.rs -assertion_line: 2448 +assertion_line: 2263 expression: "format!(\"{:#?}\", new_tab_instruction)" --- NewTab( @@ -27,6 +27,7 @@ NewTab( children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -44,6 +45,7 @@ NewTab( children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -61,6 +63,7 @@ NewTab( children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -71,6 +74,7 @@ NewTab( children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ), [], diff --git a/zellij-utils/assets/config/default.kdl b/zellij-utils/assets/config/default.kdl index 57106681d3..32dfb86e07 100644 --- a/zellij-utils/assets/config/default.kdl +++ b/zellij-utils/assets/config/default.kdl @@ -54,6 +54,9 @@ keybinds { bind "n" { NewTab; SwitchToMode "Normal"; } bind "x" { CloseTab; SwitchToMode "Normal"; } bind "s" { ToggleActiveSyncTab; SwitchToMode "Normal"; } + bind "b" { BreakPane; SwitchToMode "Normal"; } + bind "]" { BreakPaneRight; SwitchToMode "Normal"; } + bind "[" { BreakPaneLeft; SwitchToMode "Normal"; } bind "1" { GoToTab 1; SwitchToMode "Normal"; } bind "2" { GoToTab 2; SwitchToMode "Normal"; } bind "3" { GoToTab 3; SwitchToMode "Normal"; } diff --git a/zellij-utils/src/errors.rs b/zellij-utils/src/errors.rs index e2e3c244fa..df5d02782c 100644 --- a/zellij-utils/src/errors.rs +++ b/zellij-utils/src/errors.rs @@ -338,6 +338,9 @@ pub enum ScreenContext { FocusPaneWithId, RenamePane, RenameTab, + BreakPane, + BreakPaneRight, + BreakPaneLeft, } /// Stack call representations corresponding to the different types of [`PtyInstruction`]s. diff --git a/zellij-utils/src/input/actions.rs b/zellij-utils/src/input/actions.rs index 568c0a2c2c..4ed7f029cf 100644 --- a/zellij-utils/src/input/actions.rs +++ b/zellij-utils/src/input/actions.rs @@ -240,6 +240,9 @@ pub enum Action { RenameTerminalPane(u32, Vec), RenamePluginPane(u32, Vec), RenameTab(u32, Vec), + BreakPane, + BreakPaneRight, + BreakPaneLeft, } impl Action { diff --git a/zellij-utils/src/input/layout.rs b/zellij-utils/src/input/layout.rs index 55e5fc69fe..39d208e839 100644 --- a/zellij-utils/src/input/layout.rs +++ b/zellij-utils/src/input/layout.rs @@ -401,6 +401,7 @@ pub struct FloatingPaneLayout { pub y: Option, pub run: Option, pub focus: Option, + pub already_running: bool, } impl FloatingPaneLayout { @@ -438,6 +439,7 @@ pub struct TiledPaneLayout { pub children_are_stacked: bool, pub is_expanded_in_stack: bool, pub exclude_from_sync: Option, + pub run_instructions_to_ignore: Vec>, } impl TiledPaneLayout { @@ -559,8 +561,36 @@ impl TiledPaneLayout { let mut child_run_instructions = child.extract_run_instructions(); run_instructions.append(&mut child_run_instructions); } + let mut successfully_ignored = 0; + for instruction_to_ignore in &self.run_instructions_to_ignore { + if let Some(position) = run_instructions + .iter() + .position(|i| i == instruction_to_ignore) + { + run_instructions.remove(position); + successfully_ignored += 1; + } + } + // we need to do this because if we have an ignored instruction that does not match any + // running instruction, we'll have an extra pane and our state will be messed up and we'll + // crash (this can happen for example when breaking a plugin pane into a new tab that does + // not have room for it but has a terminal instead) + if successfully_ignored < self.run_instructions_to_ignore.len() { + for _ in 0..self + .run_instructions_to_ignore + .len() + .saturating_sub(successfully_ignored) + { + if let Some(position) = run_instructions.iter().position(|i| i == &None) { + run_instructions.remove(position); + } + } + } run_instructions } + pub fn ignore_run_instruction(&mut self, run_instruction: Option) { + self.run_instructions_to_ignore.push(run_instruction); + } pub fn with_one_pane() -> Self { let mut default_layout = TiledPaneLayout::default(); default_layout.children = vec![TiledPaneLayout::default()]; diff --git a/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__args_added_to_args_in_template.snap b/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__args_added_to_args_in_template.snap index d01949514c..9d2d9e37e2 100644 --- a/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__args_added_to_args_in_template.snap +++ b/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__args_added_to_args_in_template.snap @@ -1,6 +1,6 @@ --- source: zellij-utils/src/input/./unit/layout_test.rs -assertion_line: 1322 +assertion_line: 1352 expression: "format!(\"{:#?}\", layout)" --- Layout { @@ -34,6 +34,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -60,6 +61,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -70,6 +72,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, [], ), diff --git a/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__args_override_args_in_template.snap b/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__args_override_args_in_template.snap index d31f721f04..e8c140421a 100644 --- a/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__args_override_args_in_template.snap +++ b/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__args_override_args_in_template.snap @@ -1,6 +1,6 @@ --- source: zellij-utils/src/input/./unit/layout_test.rs -assertion_line: 1287 +assertion_line: 1317 expression: "format!(\"{:#?}\", layout)" --- Layout { @@ -37,6 +37,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -63,6 +64,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -73,6 +75,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, [], ), diff --git a/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__can_define_a_stack_with_an_expanded_pane.snap b/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__can_define_a_stack_with_an_expanded_pane.snap index 31ea7cb7d2..83fb940433 100644 --- a/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__can_define_a_stack_with_an_expanded_pane.snap +++ b/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__can_define_a_stack_with_an_expanded_pane.snap @@ -1,5 +1,6 @@ --- source: zellij-utils/src/input/./unit/layout_test.rs +assertion_line: 1926 expression: "format!(\"{:#?}\", layout)" --- Layout { @@ -27,6 +28,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -40,6 +42,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: true, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -53,6 +56,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -63,6 +67,7 @@ Layout { children_are_stacked: true, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -73,6 +78,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, [], ), diff --git a/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__can_define_stacked_children_for_pane_node.snap b/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__can_define_stacked_children_for_pane_node.snap index 85fa560d47..b82e9cd1e3 100644 --- a/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__can_define_stacked_children_for_pane_node.snap +++ b/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__can_define_stacked_children_for_pane_node.snap @@ -1,6 +1,6 @@ --- source: zellij-utils/src/input/./unit/layout_test.rs -assertion_line: 1864 +assertion_line: 1894 expression: "format!(\"{:#?}\", layout)" --- Layout { @@ -28,6 +28,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -41,6 +42,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -51,6 +53,7 @@ Layout { children_are_stacked: true, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -61,6 +64,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, [], ), diff --git a/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__can_define_stacked_children_for_pane_template.snap b/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__can_define_stacked_children_for_pane_template.snap index 2a6a8b2cf1..44da7ce78a 100644 --- a/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__can_define_stacked_children_for_pane_template.snap +++ b/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__can_define_stacked_children_for_pane_template.snap @@ -1,6 +1,6 @@ --- source: zellij-utils/src/input/./unit/layout_test.rs -assertion_line: 1881 +assertion_line: 1911 expression: "format!(\"{:#?}\", layout)" --- Layout { @@ -32,6 +32,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -45,6 +46,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -55,6 +57,7 @@ Layout { children_are_stacked: true, is_expanded_in_stack: true, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -65,6 +68,7 @@ Layout { children_are_stacked: true, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -75,6 +79,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, [], ), diff --git a/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__can_load_swap_layouts_from_a_different_file.snap b/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__can_load_swap_layouts_from_a_different_file.snap index e9f849b7f6..07428ee0c9 100644 --- a/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__can_load_swap_layouts_from_a_different_file.snap +++ b/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__can_load_swap_layouts_from_a_different_file.snap @@ -1,6 +1,6 @@ --- source: zellij-utils/src/input/./unit/layout_test.rs -assertion_line: 1863 +assertion_line: 1880 expression: "format!(\"{:#?}\", layout)" --- Layout { @@ -24,6 +24,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -34,6 +35,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, [], ), @@ -78,6 +80,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -99,6 +102,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -114,6 +118,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -124,6 +129,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -134,6 +140,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -165,6 +172,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -175,6 +183,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, MaxPanes( 8, @@ -212,6 +221,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -235,6 +245,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -252,6 +263,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -265,6 +277,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -278,6 +291,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -291,6 +305,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -301,6 +316,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -311,6 +327,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -321,6 +338,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -352,6 +370,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -362,6 +381,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, MaxPanes( 12, @@ -399,6 +419,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -422,6 +443,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -439,6 +461,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -452,6 +475,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -465,6 +489,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -478,6 +503,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -488,6 +514,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -505,6 +532,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -518,6 +546,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -531,6 +560,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -544,6 +574,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -554,6 +585,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -564,6 +596,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -574,6 +607,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -605,6 +639,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -615,6 +650,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, }, Some( diff --git a/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__children_not_as_first_child_of_pane_template.snap b/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__children_not_as_first_child_of_pane_template.snap index 9308614a63..4bb0487202 100644 --- a/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__children_not_as_first_child_of_pane_template.snap +++ b/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__children_not_as_first_child_of_pane_template.snap @@ -1,6 +1,6 @@ --- source: zellij-utils/src/input/./unit/layout_test.rs -assertion_line: 956 +assertion_line: 975 expression: "format!(\"{:#?}\", layout)" --- Layout { @@ -34,6 +34,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -51,6 +52,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -64,6 +66,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -74,6 +77,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -84,6 +88,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -97,6 +102,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -107,6 +113,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -128,6 +135,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -140,6 +148,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -153,6 +162,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -163,6 +173,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -173,6 +184,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, [], ), diff --git a/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__children_not_as_first_child_of_tab_template.snap b/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__children_not_as_first_child_of_tab_template.snap index 7ff5948618..c5f538f968 100644 --- a/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__children_not_as_first_child_of_tab_template.snap +++ b/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__children_not_as_first_child_of_tab_template.snap @@ -1,6 +1,6 @@ --- source: zellij-utils/src/input/./unit/layout_test.rs -assertion_line: 908 +assertion_line: 927 expression: "format!(\"{:#?}\", layout)" --- Layout { @@ -29,6 +29,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -46,6 +47,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -59,6 +61,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -69,6 +72,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -79,6 +83,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -92,6 +97,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -102,6 +108,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, [], ), @@ -127,6 +134,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -139,6 +147,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -152,6 +161,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -162,6 +172,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, [], ), @@ -181,6 +192,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, [], ), diff --git a/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__close_on_exit_added_to_close_on_exit_in_template.snap b/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__close_on_exit_added_to_close_on_exit_in_template.snap index 403980b6dd..fdd0b7f0c1 100644 --- a/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__close_on_exit_added_to_close_on_exit_in_template.snap +++ b/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__close_on_exit_added_to_close_on_exit_in_template.snap @@ -1,6 +1,6 @@ --- source: zellij-utils/src/input/./unit/layout_test.rs -assertion_line: 1339 +assertion_line: 1369 expression: "format!(\"{:#?}\", layout)" --- Layout { @@ -34,6 +34,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -57,6 +58,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -67,6 +69,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, [], ), diff --git a/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__close_on_exit_overrides_close_on_exit_in_template.snap b/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__close_on_exit_overrides_close_on_exit_in_template.snap index 23a71d4483..3a4092cff9 100644 --- a/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__close_on_exit_overrides_close_on_exit_in_template.snap +++ b/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__close_on_exit_overrides_close_on_exit_in_template.snap @@ -1,6 +1,6 @@ --- source: zellij-utils/src/input/./unit/layout_test.rs -assertion_line: 1305 +assertion_line: 1335 expression: "format!(\"{:#?}\", layout)" --- Layout { @@ -34,6 +34,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -57,6 +58,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -67,6 +69,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, [], ), diff --git a/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__combined_tab_and_pane_template_both_with_children.snap b/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__combined_tab_and_pane_template_both_with_children.snap index 80ba99b1f8..0f0a62ac0e 100644 --- a/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__combined_tab_and_pane_template_both_with_children.snap +++ b/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__combined_tab_and_pane_template_both_with_children.snap @@ -1,6 +1,6 @@ --- source: zellij-utils/src/input/./unit/layout_test.rs -assertion_line: 1008 +assertion_line: 1027 expression: "format!(\"{:#?}\", layout)" --- Layout { @@ -29,6 +29,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -48,6 +49,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -58,6 +60,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -71,6 +74,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -81,6 +85,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -98,6 +103,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -111,6 +117,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -121,6 +128,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -131,6 +139,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, [], ), @@ -156,6 +165,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -175,6 +185,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -185,6 +196,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -198,6 +210,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -208,6 +221,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -221,6 +235,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -231,6 +246,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, [], ), @@ -250,6 +266,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, [], ), diff --git a/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__cwd_added_to_cwd_in_template.snap b/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__cwd_added_to_cwd_in_template.snap index 532959f422..469eb9b977 100644 --- a/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__cwd_added_to_cwd_in_template.snap +++ b/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__cwd_added_to_cwd_in_template.snap @@ -1,6 +1,6 @@ --- source: zellij-utils/src/input/./unit/layout_test.rs -assertion_line: 1374 +assertion_line: 1404 expression: "format!(\"{:#?}\", layout)" --- Layout { @@ -34,6 +34,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -59,6 +60,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -69,6 +71,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, [], ), diff --git a/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__cwd_override_cwd_in_template.snap b/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__cwd_override_cwd_in_template.snap index 54d78e9804..42d8bcf0c9 100644 --- a/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__cwd_override_cwd_in_template.snap +++ b/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__cwd_override_cwd_in_template.snap @@ -1,6 +1,6 @@ --- source: zellij-utils/src/input/./unit/layout_test.rs -assertion_line: 1357 +assertion_line: 1387 expression: "format!(\"{:#?}\", layout)" --- Layout { @@ -36,6 +36,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -61,6 +62,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -71,6 +73,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, [], ), diff --git a/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__env_var_expansion.snap b/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__env_var_expansion.snap index de30d22961..6691e25e34 100644 --- a/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__env_var_expansion.snap +++ b/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__env_var_expansion.snap @@ -1,6 +1,6 @@ --- source: zellij-utils/src/input/./unit/layout_test.rs -assertion_line: 2116 +assertion_line: 2141 expression: "format!(\"{layout:#?}\")" --- Layout { @@ -28,6 +28,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -45,6 +46,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -62,6 +64,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -79,6 +82,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -104,6 +108,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -125,6 +130,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -146,6 +152,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -171,6 +178,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -192,6 +200,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -202,6 +211,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, [], ), diff --git a/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__global_cwd_and_tab_cwd_prepended_to_panes_with_and_without_cwd.snap b/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__global_cwd_and_tab_cwd_prepended_to_panes_with_and_without_cwd.snap index 81673d25b6..6060b071b5 100644 --- a/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__global_cwd_and_tab_cwd_prepended_to_panes_with_and_without_cwd.snap +++ b/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__global_cwd_and_tab_cwd_prepended_to_panes_with_and_without_cwd.snap @@ -1,6 +1,6 @@ --- source: zellij-utils/src/input/./unit/layout_test.rs -assertion_line: 1759 +assertion_line: 1789 expression: "format!(\"{:#?}\", layout)" --- Layout { @@ -27,6 +27,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -52,6 +53,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -66,6 +68,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, [], ), @@ -85,6 +88,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, [], ), diff --git a/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__global_cwd_and_tab_cwd_prepended_to_panes_with_and_without_cwd_in_pane_templates.snap b/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__global_cwd_and_tab_cwd_prepended_to_panes_with_and_without_cwd_in_pane_templates.snap index c87db71c77..723af76229 100644 --- a/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__global_cwd_and_tab_cwd_prepended_to_panes_with_and_without_cwd_in_pane_templates.snap +++ b/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__global_cwd_and_tab_cwd_prepended_to_panes_with_and_without_cwd_in_pane_templates.snap @@ -1,6 +1,6 @@ --- source: zellij-utils/src/input/./unit/layout_test.rs -assertion_line: 1780 +assertion_line: 1810 expression: "format!(\"{:#?}\", layout)" --- Layout { @@ -31,6 +31,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -56,6 +57,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -77,6 +79,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -91,6 +94,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -105,6 +109,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -119,6 +124,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, [], ), @@ -138,6 +144,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, [], ), diff --git a/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__global_cwd_and_tab_cwd_prepended_to_panes_with_and_without_cwd_in_tab_templates.snap b/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__global_cwd_and_tab_cwd_prepended_to_panes_with_and_without_cwd_in_tab_templates.snap index 321f36e49d..de740071ad 100644 --- a/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__global_cwd_and_tab_cwd_prepended_to_panes_with_and_without_cwd_in_tab_templates.snap +++ b/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__global_cwd_and_tab_cwd_prepended_to_panes_with_and_without_cwd_in_tab_templates.snap @@ -1,6 +1,6 @@ --- source: zellij-utils/src/input/./unit/layout_test.rs -assertion_line: 1799 +assertion_line: 1829 expression: "format!(\"{:#?}\", layout)" --- Layout { @@ -27,6 +27,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -52,6 +53,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -73,6 +75,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -87,6 +90,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -101,6 +105,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, [], ), @@ -120,6 +125,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, [], ), diff --git a/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__global_cwd_given_to_panes_without_cwd.snap b/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__global_cwd_given_to_panes_without_cwd.snap index bd9888fef4..72f9e14e33 100644 --- a/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__global_cwd_given_to_panes_without_cwd.snap +++ b/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__global_cwd_given_to_panes_without_cwd.snap @@ -1,6 +1,6 @@ --- source: zellij-utils/src/input/./unit/layout_test.rs -assertion_line: 1644 +assertion_line: 1674 expression: "format!(\"{:#?}\", layout)" --- Layout { @@ -28,6 +28,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -53,6 +54,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -63,6 +65,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, [], ), diff --git a/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__global_cwd_passed_from_layout_constructor.snap b/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__global_cwd_passed_from_layout_constructor.snap index f871ff739d..b6a29005b3 100644 --- a/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__global_cwd_passed_from_layout_constructor.snap +++ b/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__global_cwd_passed_from_layout_constructor.snap @@ -1,6 +1,6 @@ --- source: zellij-utils/src/input/./unit/layout_test.rs -assertion_line: 1677 +assertion_line: 1707 expression: "format!(\"{:#?}\", layout)" --- Layout { @@ -28,6 +28,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -53,6 +54,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -63,6 +65,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, [], ), diff --git a/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__global_cwd_passed_from_layout_constructor_overrides_global_cwd_in_layout_file.snap b/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__global_cwd_passed_from_layout_constructor_overrides_global_cwd_in_layout_file.snap index d7b8582218..c673885a68 100644 --- a/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__global_cwd_passed_from_layout_constructor_overrides_global_cwd_in_layout_file.snap +++ b/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__global_cwd_passed_from_layout_constructor_overrides_global_cwd_in_layout_file.snap @@ -1,6 +1,6 @@ --- source: zellij-utils/src/input/./unit/layout_test.rs -assertion_line: 1698 +assertion_line: 1728 expression: "format!(\"{:#?}\", layout)" --- Layout { @@ -28,6 +28,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -53,6 +54,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -63,6 +65,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, [], ), diff --git a/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__global_cwd_prepended_to_panes_with_cwd.snap b/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__global_cwd_prepended_to_panes_with_cwd.snap index 770a43cc3c..41678b395c 100644 --- a/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__global_cwd_prepended_to_panes_with_cwd.snap +++ b/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__global_cwd_prepended_to_panes_with_cwd.snap @@ -1,6 +1,6 @@ --- source: zellij-utils/src/input/./unit/layout_test.rs -assertion_line: 1657 +assertion_line: 1687 expression: "format!(\"{:#?}\", layout)" --- Layout { @@ -28,6 +28,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -53,6 +54,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -63,6 +65,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, [], ), diff --git a/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__global_cwd_with_tab_cwd_given_to_panes_without_cwd.snap b/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__global_cwd_with_tab_cwd_given_to_panes_without_cwd.snap index b9829595ce..d386d9c94b 100644 --- a/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__global_cwd_with_tab_cwd_given_to_panes_without_cwd.snap +++ b/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__global_cwd_with_tab_cwd_given_to_panes_without_cwd.snap @@ -1,6 +1,6 @@ --- source: zellij-utils/src/input/./unit/layout_test.rs -assertion_line: 1714 +assertion_line: 1744 expression: "format!(\"{:#?}\", layout)" --- Layout { @@ -27,6 +27,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -52,6 +53,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -66,6 +68,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, [], ), @@ -85,6 +88,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, [], ), diff --git a/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__layout_with_command_panes_and_close_on_exit.snap b/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__layout_with_command_panes_and_close_on_exit.snap index 4f5c5e0bb1..b213ea2115 100644 --- a/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__layout_with_command_panes_and_close_on_exit.snap +++ b/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__layout_with_command_panes_and_close_on_exit.snap @@ -34,6 +34,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -44,6 +45,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, [], ), diff --git a/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__layout_with_command_panes_and_start_suspended.snap b/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__layout_with_command_panes_and_start_suspended.snap index 9f118820a5..35c343730c 100644 --- a/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__layout_with_command_panes_and_start_suspended.snap +++ b/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__layout_with_command_panes_and_start_suspended.snap @@ -34,6 +34,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -44,6 +45,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, [], ), diff --git a/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__layout_with_default_tab_template.snap b/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__layout_with_default_tab_template.snap index bec76e1184..92e58f7d97 100644 --- a/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__layout_with_default_tab_template.snap +++ b/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__layout_with_default_tab_template.snap @@ -1,6 +1,6 @@ --- source: zellij-utils/src/input/./unit/layout_test.rs -assertion_line: 767 +assertion_line: 786 expression: "format!(\"{:#?}\", layout)" --- Layout { @@ -25,6 +25,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Vertical, @@ -42,6 +43,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -55,6 +57,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -65,6 +68,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -78,6 +82,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -88,6 +93,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, [], ), @@ -111,6 +117,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -128,6 +135,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -141,6 +149,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -151,6 +160,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -164,6 +174,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -174,6 +185,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, [], ), @@ -195,6 +207,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -208,6 +221,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -221,6 +235,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -231,6 +246,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, [], ), @@ -254,6 +270,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -267,6 +284,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -280,6 +298,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -290,6 +309,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, [], ), diff --git a/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__layout_with_nested_branched_pane_templates.snap b/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__layout_with_nested_branched_pane_templates.snap index d3b743e17e..707ec26822 100644 --- a/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__layout_with_nested_branched_pane_templates.snap +++ b/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__layout_with_nested_branched_pane_templates.snap @@ -1,6 +1,6 @@ --- source: zellij-utils/src/input/./unit/layout_test.rs -assertion_line: 862 +assertion_line: 881 expression: "format!(\"{:#?}\", layout)" --- Layout { @@ -28,6 +28,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -41,6 +42,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -58,6 +60,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -71,6 +74,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -81,6 +85,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -98,6 +103,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -111,6 +117,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -124,6 +131,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -134,6 +142,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -144,6 +153,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -154,6 +164,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, [], ), diff --git a/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__layout_with_nested_pane_templates.snap b/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__layout_with_nested_pane_templates.snap index 8a6dce5223..ce8ee0a96d 100644 --- a/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__layout_with_nested_pane_templates.snap +++ b/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__layout_with_nested_pane_templates.snap @@ -1,6 +1,6 @@ --- source: zellij-utils/src/input/./unit/layout_test.rs -assertion_line: 836 +assertion_line: 855 expression: "format!(\"{:#?}\", layout)" --- Layout { @@ -28,6 +28,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -41,6 +42,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -58,6 +60,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -71,6 +74,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -81,6 +85,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -94,6 +99,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -104,6 +110,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -114,6 +121,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, [], ), diff --git a/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__layout_with_pane_excluded_from_sync.snap b/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__layout_with_pane_excluded_from_sync.snap index 25f7dc0764..554420b1dd 100644 --- a/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__layout_with_pane_excluded_from_sync.snap +++ b/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__layout_with_pane_excluded_from_sync.snap @@ -1,5 +1,6 @@ --- source: zellij-utils/src/input/./unit/layout_test.rs +assertion_line: 1038 expression: "format!(\"{:#?}\", layout)" --- Layout { @@ -25,6 +26,7 @@ Layout { exclude_from_sync: Some( true, ), + run_instructions_to_ignore: [], }, ], split_size: None, @@ -35,6 +37,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, [], ), diff --git a/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__layout_with_pane_templates.snap b/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__layout_with_pane_templates.snap index ff18632fd5..0eeb76af4d 100644 --- a/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__layout_with_pane_templates.snap +++ b/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__layout_with_pane_templates.snap @@ -1,6 +1,6 @@ --- source: zellij-utils/src/input/./unit/layout_test.rs -assertion_line: 794 +assertion_line: 813 expression: "format!(\"{:#?}\", layout)" --- Layout { @@ -28,6 +28,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -45,6 +46,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -55,6 +57,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -68,6 +71,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -78,6 +82,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Vertical, @@ -95,6 +100,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -112,6 +118,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -125,6 +132,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -135,6 +143,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -148,6 +157,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -158,6 +168,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Vertical, @@ -175,6 +186,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Vertical, @@ -192,6 +204,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -205,6 +218,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -215,6 +229,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -228,6 +243,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -238,6 +254,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Vertical, @@ -255,6 +272,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -268,6 +286,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -281,6 +300,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -291,6 +311,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -301,6 +322,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, [], ), diff --git a/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__layout_with_tab_and_pane_templates.snap b/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__layout_with_tab_and_pane_templates.snap index 78f47b4935..1bc1b01c64 100644 --- a/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__layout_with_tab_and_pane_templates.snap +++ b/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__layout_with_tab_and_pane_templates.snap @@ -1,6 +1,6 @@ --- source: zellij-utils/src/input/./unit/layout_test.rs -assertion_line: 815 +assertion_line: 834 expression: "format!(\"{:#?}\", layout)" --- Layout { @@ -27,6 +27,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -54,6 +55,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -64,6 +66,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -77,6 +80,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -87,6 +91,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -97,6 +102,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, [], ), @@ -116,6 +122,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, [], ), diff --git a/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__layout_with_tabs_and_floating_panes.snap b/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__layout_with_tabs_and_floating_panes.snap index b993cec3e0..c9776160e4 100644 --- a/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__layout_with_tabs_and_floating_panes.snap +++ b/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__layout_with_tabs_and_floating_panes.snap @@ -23,6 +23,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -33,6 +34,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, [ FloatingPaneLayout { @@ -43,6 +45,7 @@ Layout { y: None, run: None, focus: None, + already_running: false, }, ], ), @@ -64,6 +67,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -74,6 +78,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, [ FloatingPaneLayout { @@ -84,6 +89,7 @@ Layout { y: None, run: None, focus: None, + already_running: false, }, FloatingPaneLayout { name: None, @@ -93,6 +99,7 @@ Layout { y: None, run: None, focus: None, + already_running: false, }, ], ), @@ -112,6 +119,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, [], ), diff --git a/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__pane_template_command_with_cwd_is_overriden_by_its_consumers_bare_cwd.snap b/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__pane_template_command_with_cwd_is_overriden_by_its_consumers_bare_cwd.snap index 849b9b6d1f..a8bff78ed8 100644 --- a/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__pane_template_command_with_cwd_is_overriden_by_its_consumers_bare_cwd.snap +++ b/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__pane_template_command_with_cwd_is_overriden_by_its_consumers_bare_cwd.snap @@ -1,6 +1,6 @@ --- source: zellij-utils/src/input/./unit/layout_test.rs -assertion_line: 1528 +assertion_line: 1558 expression: "format!(\"{:#?}\", layout)" --- Layout { @@ -36,6 +36,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -46,6 +47,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, [], ), diff --git a/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__pane_template_command_with_cwd_overriden_by_its_consumers_command_cwd.snap b/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__pane_template_command_with_cwd_overriden_by_its_consumers_command_cwd.snap index e7b200fd55..433283fcda 100644 --- a/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__pane_template_command_with_cwd_overriden_by_its_consumers_command_cwd.snap +++ b/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__pane_template_command_with_cwd_overriden_by_its_consumers_command_cwd.snap @@ -1,6 +1,6 @@ --- source: zellij-utils/src/input/./unit/layout_test.rs -assertion_line: 1474 +assertion_line: 1504 expression: "format!(\"{:#?}\", layout)" --- Layout { @@ -36,6 +36,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -46,6 +47,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, [], ), diff --git a/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__pane_template_command_with_cwd_remains_when_its_consumer_command_does_not_have_a_cwd.snap b/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__pane_template_command_with_cwd_remains_when_its_consumer_command_does_not_have_a_cwd.snap index ed4a906b4e..8d06ac560b 100644 --- a/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__pane_template_command_with_cwd_remains_when_its_consumer_command_does_not_have_a_cwd.snap +++ b/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__pane_template_command_with_cwd_remains_when_its_consumer_command_does_not_have_a_cwd.snap @@ -1,6 +1,6 @@ --- source: zellij-utils/src/input/./unit/layout_test.rs -assertion_line: 1491 +assertion_line: 1521 expression: "format!(\"{:#?}\", layout)" --- Layout { @@ -36,6 +36,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -46,6 +47,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, [], ), diff --git a/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__pane_template_command_without_cwd_is_overriden_by_its_consumers_cwd.snap b/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__pane_template_command_without_cwd_is_overriden_by_its_consumers_cwd.snap index 0fc98b67bd..5d7f6b9918 100644 --- a/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__pane_template_command_without_cwd_is_overriden_by_its_consumers_cwd.snap +++ b/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__pane_template_command_without_cwd_is_overriden_by_its_consumers_cwd.snap @@ -1,6 +1,6 @@ --- source: zellij-utils/src/input/./unit/layout_test.rs -assertion_line: 1509 +assertion_line: 1539 expression: "format!(\"{:#?}\", layout)" --- Layout { @@ -36,6 +36,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -46,6 +47,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, [], ), diff --git a/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__pane_template_command_without_cwd_receives_its_consumers_bare_cwd.snap b/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__pane_template_command_without_cwd_receives_its_consumers_bare_cwd.snap index 8f0411100e..f49d65f4f8 100644 --- a/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__pane_template_command_without_cwd_receives_its_consumers_bare_cwd.snap +++ b/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__pane_template_command_without_cwd_receives_its_consumers_bare_cwd.snap @@ -1,6 +1,6 @@ --- source: zellij-utils/src/input/./unit/layout_test.rs -assertion_line: 1546 +assertion_line: 1576 expression: "format!(\"{:#?}\", layout)" --- Layout { @@ -36,6 +36,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -46,6 +47,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, [], ), diff --git a/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__pane_template_with_bare_cwd_overriden_by_its_consumers_bare_cwd.snap b/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__pane_template_with_bare_cwd_overriden_by_its_consumers_bare_cwd.snap index 9fc4aaf122..cf7c7b7a31 100644 --- a/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__pane_template_with_bare_cwd_overriden_by_its_consumers_bare_cwd.snap +++ b/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__pane_template_with_bare_cwd_overriden_by_its_consumers_bare_cwd.snap @@ -1,6 +1,6 @@ --- source: zellij-utils/src/input/./unit/layout_test.rs -assertion_line: 1564 +assertion_line: 1594 expression: "format!(\"{:#?}\", layout)" --- Layout { @@ -28,6 +28,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -38,6 +39,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, [], ), diff --git a/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__pane_template_with_bare_propagated_to_its_consumer_command_with_cwd.snap b/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__pane_template_with_bare_propagated_to_its_consumer_command_with_cwd.snap index d0125554fb..c55fb95213 100644 --- a/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__pane_template_with_bare_propagated_to_its_consumer_command_with_cwd.snap +++ b/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__pane_template_with_bare_propagated_to_its_consumer_command_with_cwd.snap @@ -1,6 +1,6 @@ --- source: zellij-utils/src/input/./unit/layout_test.rs -assertion_line: 1598 +assertion_line: 1628 expression: "format!(\"{:#?}\", layout)" --- Layout { @@ -36,6 +36,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -46,6 +47,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, [], ), diff --git a/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__pane_template_with_bare_propagated_to_its_consumer_command_without_cwd.snap b/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__pane_template_with_bare_propagated_to_its_consumer_command_without_cwd.snap index d9bbf77a88..34280469a2 100644 --- a/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__pane_template_with_bare_propagated_to_its_consumer_command_without_cwd.snap +++ b/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__pane_template_with_bare_propagated_to_its_consumer_command_without_cwd.snap @@ -1,6 +1,6 @@ --- source: zellij-utils/src/input/./unit/layout_test.rs -assertion_line: 1580 +assertion_line: 1610 expression: "format!(\"{:#?}\", layout)" --- Layout { @@ -36,6 +36,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -46,6 +47,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, [], ), diff --git a/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__pane_template_with_bare_propagated_to_its_consumer_edit.snap b/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__pane_template_with_bare_propagated_to_its_consumer_edit.snap index be2f0fb428..faac5c46d3 100644 --- a/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__pane_template_with_bare_propagated_to_its_consumer_edit.snap +++ b/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__pane_template_with_bare_propagated_to_its_consumer_edit.snap @@ -1,5 +1,6 @@ --- source: zellij-utils/src/input/./unit/layout_test.rs +assertion_line: 1644 expression: "format!(\"{:#?}\", layout)" --- Layout { @@ -31,6 +32,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -41,6 +43,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, [], ), diff --git a/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__pane_template_with_command_propagated_to_its_consumer_edit.snap b/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__pane_template_with_command_propagated_to_its_consumer_edit.snap index a33fc2bdac..5930f95184 100644 --- a/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__pane_template_with_command_propagated_to_its_consumer_edit.snap +++ b/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__pane_template_with_command_propagated_to_its_consumer_edit.snap @@ -1,5 +1,6 @@ --- source: zellij-utils/src/input/./unit/layout_test.rs +assertion_line: 1660 expression: "format!(\"{:#?}\", layout)" --- Layout { @@ -31,6 +32,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -41,6 +43,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, [], ), diff --git a/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__tab_cwd_given_to_panes_without_cwd.snap b/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__tab_cwd_given_to_panes_without_cwd.snap index a74656108e..98b7a5cd8e 100644 --- a/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__tab_cwd_given_to_panes_without_cwd.snap +++ b/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__tab_cwd_given_to_panes_without_cwd.snap @@ -1,6 +1,6 @@ --- source: zellij-utils/src/input/./unit/layout_test.rs -assertion_line: 1729 +assertion_line: 1759 expression: "format!(\"{:#?}\", layout)" --- Layout { @@ -27,6 +27,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -52,6 +53,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -66,6 +68,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, [], ), @@ -85,6 +88,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, [], ), diff --git a/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__tab_cwd_prepended_to_panes_with_cwd.snap b/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__tab_cwd_prepended_to_panes_with_cwd.snap index 65ed2b5031..5ca79f19e2 100644 --- a/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__tab_cwd_prepended_to_panes_with_cwd.snap +++ b/zellij-utils/src/input/unit/snapshots/zellij_utils__input__layout__layout_test__tab_cwd_prepended_to_panes_with_cwd.snap @@ -1,6 +1,6 @@ --- source: zellij-utils/src/input/./unit/layout_test.rs -assertion_line: 1744 +assertion_line: 1774 expression: "format!(\"{:#?}\", layout)" --- Layout { @@ -27,6 +27,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -52,6 +53,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -66,6 +68,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, [], ), @@ -85,6 +88,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, [], ), diff --git a/zellij-utils/src/kdl/mod.rs b/zellij-utils/src/kdl/mod.rs index 341415c1cd..a75a4a638e 100644 --- a/zellij-utils/src/kdl/mod.rs +++ b/zellij-utils/src/kdl/mod.rs @@ -915,6 +915,9 @@ impl TryFrom<(&KdlNode, &Options)> for Action { }, "PreviousSwapLayout" => Ok(Action::PreviousSwapLayout), "NextSwapLayout" => Ok(Action::NextSwapLayout), + "BreakPane" => Ok(Action::BreakPane), + "BreakPaneRight" => Ok(Action::BreakPaneRight), + "BreakPaneLeft" => Ok(Action::BreakPaneLeft), _ => Err(ConfigError::new_kdl_error( format!("Unsupported action: {}", action_name).into(), kdl_action.span().offset(), diff --git a/zellij-utils/src/pane_size.rs b/zellij-utils/src/pane_size.rs index 1df73a32db..bef4f652a0 100644 --- a/zellij-utils/src/pane_size.rs +++ b/zellij-utils/src/pane_size.rs @@ -22,6 +22,12 @@ pub struct Viewport { pub cols: usize, } +impl Viewport { + pub fn has_positive_size(&self) -> bool { + self.rows > 0 && self.cols > 0 + } +} + #[derive(Clone, Copy, Debug, Default, Serialize, Deserialize, PartialEq, Eq)] pub struct Offset { pub top: usize, diff --git a/zellij-utils/src/snapshots/zellij_utils__setup__setup_test__cli_arguments_override_layout_options-2.snap b/zellij-utils/src/snapshots/zellij_utils__setup__setup_test__cli_arguments_override_layout_options-2.snap index 452f0a8be5..a3d69ce85b 100644 --- a/zellij-utils/src/snapshots/zellij_utils__setup__setup_test__cli_arguments_override_layout_options-2.snap +++ b/zellij-utils/src/snapshots/zellij_utils__setup__setup_test__cli_arguments_override_layout_options-2.snap @@ -1,6 +1,6 @@ --- source: zellij-utils/src/setup.rs -assertion_line: 665 +assertion_line: 683 expression: "format!(\"{:#?}\", layout)" --- Layout { @@ -20,6 +20,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, [], ), diff --git a/zellij-utils/src/snapshots/zellij_utils__setup__setup_test__default_config_with_no_cli_arguments-2.snap b/zellij-utils/src/snapshots/zellij_utils__setup__setup_test__default_config_with_no_cli_arguments-2.snap index e294f81732..f68f6c5baa 100644 --- a/zellij-utils/src/snapshots/zellij_utils__setup__setup_test__default_config_with_no_cli_arguments-2.snap +++ b/zellij-utils/src/snapshots/zellij_utils__setup__setup_test__default_config_with_no_cli_arguments-2.snap @@ -42,6 +42,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -55,6 +56,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -86,6 +88,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -96,6 +99,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, [], ), @@ -140,6 +144,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -161,6 +166,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -176,6 +182,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -186,6 +193,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -196,6 +204,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -227,6 +236,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -237,6 +247,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, MaxPanes( 8, @@ -274,6 +285,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -297,6 +309,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -314,6 +327,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -327,6 +341,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -340,6 +355,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -353,6 +369,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -363,6 +380,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -373,6 +391,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -383,6 +402,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -414,6 +434,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -424,6 +445,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, MaxPanes( 12, @@ -461,6 +483,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -484,6 +507,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -501,6 +525,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -514,6 +539,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -527,6 +553,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -540,6 +567,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -550,6 +578,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -567,6 +596,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -580,6 +610,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -593,6 +624,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -606,6 +638,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -616,6 +649,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -626,6 +660,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -636,6 +671,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -667,6 +703,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -677,6 +714,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, }, Some( @@ -721,6 +759,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -738,6 +777,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -751,6 +791,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -761,6 +802,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -792,6 +834,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -802,6 +845,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, MaxPanes( 8, @@ -839,6 +883,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -862,6 +907,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Vertical, @@ -879,6 +925,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -892,6 +939,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -905,6 +953,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -918,6 +967,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -928,6 +978,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -938,6 +989,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -948,6 +1000,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -979,6 +1032,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -989,6 +1043,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, MaxPanes( 12, @@ -1026,6 +1081,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -1049,6 +1105,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Vertical, @@ -1066,6 +1123,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -1079,6 +1137,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -1092,6 +1151,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -1105,6 +1165,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -1115,6 +1176,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Vertical, @@ -1132,6 +1194,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -1145,6 +1208,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -1158,6 +1222,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -1171,6 +1236,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -1181,6 +1247,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -1191,6 +1258,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -1201,6 +1269,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -1232,6 +1301,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -1242,6 +1312,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, }, Some( @@ -1286,6 +1357,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -1307,6 +1379,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -1322,6 +1395,7 @@ Layout { children_are_stacked: true, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -1332,6 +1406,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -1342,6 +1417,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, TiledPaneLayout { children_split_direction: Horizontal, @@ -1373,6 +1449,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, ], split_size: None, @@ -1383,6 +1460,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, }, Some( @@ -1428,6 +1506,7 @@ Layout { ), run: None, focus: None, + already_running: false, }, FloatingPaneLayout { name: None, @@ -1453,6 +1532,7 @@ Layout { ), run: None, focus: None, + already_running: false, }, FloatingPaneLayout { name: None, @@ -1478,6 +1558,7 @@ Layout { ), run: None, focus: None, + already_running: false, }, FloatingPaneLayout { name: None, @@ -1503,6 +1584,7 @@ Layout { ), run: None, focus: None, + already_running: false, }, FloatingPaneLayout { name: None, @@ -1528,6 +1610,7 @@ Layout { ), run: None, focus: None, + already_running: false, }, FloatingPaneLayout { name: None, @@ -1553,6 +1636,7 @@ Layout { ), run: None, focus: None, + already_running: false, }, FloatingPaneLayout { name: None, @@ -1578,6 +1662,7 @@ Layout { ), run: None, focus: None, + already_running: false, }, FloatingPaneLayout { name: None, @@ -1603,6 +1688,7 @@ Layout { ), run: None, focus: None, + already_running: false, }, FloatingPaneLayout { name: None, @@ -1628,6 +1714,7 @@ Layout { ), run: None, focus: None, + already_running: false, }, FloatingPaneLayout { name: None, @@ -1655,6 +1742,7 @@ Layout { focus: Some( true, ), + already_running: false, }, ], }, @@ -1683,6 +1771,7 @@ Layout { ), run: None, focus: None, + already_running: false, }, ], MaxPanes( @@ -1708,6 +1797,7 @@ Layout { ), run: None, focus: None, + already_running: false, }, FloatingPaneLayout { name: None, @@ -1729,6 +1819,7 @@ Layout { ), run: None, focus: None, + already_running: false, }, ], MaxPanes( @@ -1756,6 +1847,7 @@ Layout { focus: Some( true, ), + already_running: false, }, FloatingPaneLayout { name: None, @@ -1777,6 +1869,7 @@ Layout { ), run: None, focus: None, + already_running: false, }, FloatingPaneLayout { name: None, @@ -1798,6 +1891,7 @@ Layout { ), run: None, focus: None, + already_running: false, }, ], MaxPanes( @@ -1827,6 +1921,7 @@ Layout { ), run: None, focus: None, + already_running: false, }, FloatingPaneLayout { name: None, @@ -1854,6 +1949,7 @@ Layout { focus: Some( true, ), + already_running: false, }, FloatingPaneLayout { name: None, @@ -1879,6 +1975,7 @@ Layout { ), run: None, focus: None, + already_running: false, }, FloatingPaneLayout { name: None, @@ -1904,6 +2001,7 @@ Layout { ), run: None, focus: None, + already_running: false, }, ], }, diff --git a/zellij-utils/src/snapshots/zellij_utils__setup__setup_test__default_config_with_no_cli_arguments.snap b/zellij-utils/src/snapshots/zellij_utils__setup__setup_test__default_config_with_no_cli_arguments.snap index 23da443fc1..7f681757df 100644 --- a/zellij-utils/src/snapshots/zellij_utils__setup__setup_test__default_config_with_no_cli_arguments.snap +++ b/zellij-utils/src/snapshots/zellij_utils__setup__setup_test__default_config_with_no_cli_arguments.snap @@ -993,6 +993,30 @@ Config { Normal, ), ], + Char( + '[', + ): [ + BreakPaneLeft, + SwitchToMode( + Normal, + ), + ], + Char( + ']', + ): [ + BreakPaneRight, + SwitchToMode( + Normal, + ), + ], + Char( + 'b', + ): [ + BreakPane, + SwitchToMode( + Normal, + ), + ], Char( 'h', ): [ diff --git a/zellij-utils/src/snapshots/zellij_utils__setup__setup_test__layout_env_vars_override_config_env_vars.snap b/zellij-utils/src/snapshots/zellij_utils__setup__setup_test__layout_env_vars_override_config_env_vars.snap index e5f37d87a4..f8cbc41322 100644 --- a/zellij-utils/src/snapshots/zellij_utils__setup__setup_test__layout_env_vars_override_config_env_vars.snap +++ b/zellij-utils/src/snapshots/zellij_utils__setup__setup_test__layout_env_vars_override_config_env_vars.snap @@ -993,6 +993,30 @@ Config { Normal, ), ], + Char( + '[', + ): [ + BreakPaneLeft, + SwitchToMode( + Normal, + ), + ], + Char( + ']', + ): [ + BreakPaneRight, + SwitchToMode( + Normal, + ), + ], + Char( + 'b', + ): [ + BreakPane, + SwitchToMode( + Normal, + ), + ], Char( 'h', ): [ diff --git a/zellij-utils/src/snapshots/zellij_utils__setup__setup_test__layout_options_override_config_options-2.snap b/zellij-utils/src/snapshots/zellij_utils__setup__setup_test__layout_options_override_config_options-2.snap index 4caba6fbe7..4f5321b166 100644 --- a/zellij-utils/src/snapshots/zellij_utils__setup__setup_test__layout_options_override_config_options-2.snap +++ b/zellij-utils/src/snapshots/zellij_utils__setup__setup_test__layout_options_override_config_options-2.snap @@ -1,6 +1,6 @@ --- source: zellij-utils/src/setup.rs -assertion_line: 647 +assertion_line: 665 expression: "format!(\"{:#?}\", layout)" --- Layout { @@ -20,6 +20,7 @@ Layout { children_are_stacked: false, is_expanded_in_stack: false, exclude_from_sync: None, + run_instructions_to_ignore: [], }, [], ), diff --git a/zellij-utils/src/snapshots/zellij_utils__setup__setup_test__layout_plugins_override_config_plugins.snap b/zellij-utils/src/snapshots/zellij_utils__setup__setup_test__layout_plugins_override_config_plugins.snap index 5540a57105..435016634a 100644 --- a/zellij-utils/src/snapshots/zellij_utils__setup__setup_test__layout_plugins_override_config_plugins.snap +++ b/zellij-utils/src/snapshots/zellij_utils__setup__setup_test__layout_plugins_override_config_plugins.snap @@ -993,6 +993,30 @@ Config { Normal, ), ], + Char( + '[', + ): [ + BreakPaneLeft, + SwitchToMode( + Normal, + ), + ], + Char( + ']', + ): [ + BreakPaneRight, + SwitchToMode( + Normal, + ), + ], + Char( + 'b', + ): [ + BreakPane, + SwitchToMode( + Normal, + ), + ], Char( 'h', ): [ diff --git a/zellij-utils/src/snapshots/zellij_utils__setup__setup_test__layout_themes_override_config_themes.snap b/zellij-utils/src/snapshots/zellij_utils__setup__setup_test__layout_themes_override_config_themes.snap index b885dafffc..4159c5254f 100644 --- a/zellij-utils/src/snapshots/zellij_utils__setup__setup_test__layout_themes_override_config_themes.snap +++ b/zellij-utils/src/snapshots/zellij_utils__setup__setup_test__layout_themes_override_config_themes.snap @@ -993,6 +993,30 @@ Config { Normal, ), ], + Char( + '[', + ): [ + BreakPaneLeft, + SwitchToMode( + Normal, + ), + ], + Char( + ']', + ): [ + BreakPaneRight, + SwitchToMode( + Normal, + ), + ], + Char( + 'b', + ): [ + BreakPane, + SwitchToMode( + Normal, + ), + ], Char( 'h', ): [ diff --git a/zellij-utils/src/snapshots/zellij_utils__setup__setup_test__layout_ui_config_overrides_config_ui_config.snap b/zellij-utils/src/snapshots/zellij_utils__setup__setup_test__layout_ui_config_overrides_config_ui_config.snap index b371b61ff3..ebf3c501e2 100644 --- a/zellij-utils/src/snapshots/zellij_utils__setup__setup_test__layout_ui_config_overrides_config_ui_config.snap +++ b/zellij-utils/src/snapshots/zellij_utils__setup__setup_test__layout_ui_config_overrides_config_ui_config.snap @@ -993,6 +993,30 @@ Config { Normal, ), ], + Char( + '[', + ): [ + BreakPaneLeft, + SwitchToMode( + Normal, + ), + ], + Char( + ']', + ): [ + BreakPaneRight, + SwitchToMode( + Normal, + ), + ], + Char( + 'b', + ): [ + BreakPane, + SwitchToMode( + Normal, + ), + ], Char( 'h', ): [