diff options
author | Aram Drevekenin <aram@poor.dev> | 2024-03-25 14:22:52 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-03-25 14:22:52 +0100 |
commit | 223730f04a008237fc0b78b788cfc62dd896d51c (patch) | |
tree | 289fec6661209f3784cf622384285f8572340a9f | |
parent | 8b2263ecf3906ebb7f14ba5f68641966eb06297c (diff) |
style(fmt): fix warnings (#3223)
* fix warnings in zellij-server
* style(fmt): remove warnings
* style(fmt): rustfmt
-rw-r--r-- | zellij-server/src/os_input_output.rs | 2 | ||||
-rw-r--r-- | zellij-server/src/panes/floating_panes/mod.rs | 2 | ||||
-rw-r--r-- | zellij-server/src/panes/tiled_panes/mod.rs | 2 | ||||
-rw-r--r-- | zellij-server/src/pty.rs | 9 | ||||
-rw-r--r-- | zellij-server/src/screen.rs | 6 | ||||
-rw-r--r-- | zellij-server/src/tab/mod.rs | 4 | ||||
-rw-r--r-- | zellij-utils/src/plugin_api/event.rs | 1 |
7 files changed, 13 insertions, 13 deletions
diff --git a/zellij-server/src/os_input_output.rs b/zellij-server/src/os_input_output.rs index 25e2cafe2..a2d9e36a8 100644 --- a/zellij-server/src/os_input_output.rs +++ b/zellij-server/src/os_input_output.rs @@ -443,7 +443,7 @@ struct RawFdAsyncReader { impl RawFdAsyncReader { fn new(fd: RawFd) -> RawFdAsyncReader { RawFdAsyncReader { - /// The supplied `RawFd` is consumed by the created `RawFdAsyncReader`, closing it when dropped + // The supplied `RawFd` is consumed by the created `RawFdAsyncReader`, closing it when dropped fd: unsafe { AsyncFile::from_raw_fd(fd) }, } } diff --git a/zellij-server/src/panes/floating_panes/mod.rs b/zellij-server/src/panes/floating_panes/mod.rs index 07ed6173d..c9166ce19 100644 --- a/zellij-server/src/panes/floating_panes/mod.rs +++ b/zellij-server/src/panes/floating_panes/mod.rs @@ -25,7 +25,7 @@ use zellij_utils::{ data::{ModeInfo, Style}, errors::prelude::*, input::command::RunCommand, - input::layout::{FloatingPaneLayout, Run, RunPlugin, RunPluginOrAlias}, + input::layout::{FloatingPaneLayout, Run, RunPluginOrAlias}, pane_size::{Dimension, Offset, PaneGeom, Size, SizeInPixels, Viewport}, }; diff --git a/zellij-server/src/panes/tiled_panes/mod.rs b/zellij-server/src/panes/tiled_panes/mod.rs index c54a54fdc..9c2458c2c 100644 --- a/zellij-server/src/panes/tiled_panes/mod.rs +++ b/zellij-server/src/panes/tiled_panes/mod.rs @@ -22,7 +22,7 @@ use zellij_utils::{ errors::prelude::*, input::{ command::RunCommand, - layout::{Run, RunPlugin, RunPluginOrAlias, SplitDirection}, + layout::{Run, RunPluginOrAlias, SplitDirection}, }, pane_size::{Offset, PaneGeom, Size, SizeInPixels, Viewport}, }; diff --git a/zellij-server/src/pty.rs b/zellij-server/src/pty.rs index 209970530..cc219f372 100644 --- a/zellij-server/src/pty.rs +++ b/zellij-server/src/pty.rs @@ -18,10 +18,7 @@ use zellij_utils::{ errors::{ContextType, PtyContext}, input::{ command::{RunCommand, TerminalAction}, - layout::{ - FloatingPaneLayout, Layout, PluginUserConfiguration, Run, RunPluginLocation, - RunPluginOrAlias, TiledPaneLayout, - }, + layout::{FloatingPaneLayout, Layout, Run, RunPluginOrAlias, TiledPaneLayout}, }, pane_size::Size, session_serialization, @@ -1344,7 +1341,9 @@ impl Pty { size: Size, skip_cache: bool, cwd: Option<PathBuf>, - floating_pane_coordinates: Option<FloatingPaneCoordinates>, + // left here for historical and potential future reasons since we might change the ordering + // of the pipeline between threads and end up needing to forward this + _floating_pane_coordinates: Option<FloatingPaneCoordinates>, ) -> Result<()> { let cwd = cwd.or_else(|| { self.active_panes diff --git a/zellij-server/src/screen.rs b/zellij-server/src/screen.rs index 94b91777d..35ec8fee5 100644 --- a/zellij-server/src/screen.rs +++ b/zellij-server/src/screen.rs @@ -20,8 +20,8 @@ use zellij_utils::{ envs::set_session_name, input::command::TerminalAction, input::layout::{ - FloatingPaneLayout, Layout, Run, RunPlugin, RunPluginLocation, RunPluginOrAlias, - SwapFloatingLayout, SwapTiledLayout, TiledPaneLayout, + FloatingPaneLayout, Layout, Run, RunPluginOrAlias, SwapFloatingLayout, SwapTiledLayout, + TiledPaneLayout, }, position::Position, }; @@ -3865,7 +3865,7 @@ pub(crate) fn screen_thread_main( // update state screen.session_name = name.clone(); screen.default_mode_info.session_name = Some(name.clone()); - for (_client_id, mut mode_info) in screen.mode_info.iter_mut() { + for (_client_id, mode_info) in screen.mode_info.iter_mut() { mode_info.session_name = Some(name.clone()); } for (_, tab) in screen.tabs.iter_mut() { diff --git a/zellij-server/src/tab/mod.rs b/zellij-server/src/tab/mod.rs index 8c135b7d0..089ba2e14 100644 --- a/zellij-server/src/tab/mod.rs +++ b/zellij-server/src/tab/mod.rs @@ -50,8 +50,8 @@ use zellij_utils::{ input::{ command::TerminalAction, layout::{ - FloatingPaneLayout, PluginUserConfiguration, Run, RunPlugin, RunPluginLocation, - RunPluginOrAlias, SwapFloatingLayout, SwapTiledLayout, TiledPaneLayout, + FloatingPaneLayout, Run, RunPluginOrAlias, SwapFloatingLayout, SwapTiledLayout, + TiledPaneLayout, }, parse_keys, }, diff --git a/zellij-utils/src/plugin_api/event.rs b/zellij-utils/src/plugin_api/event.rs index 1b2cbce29..04380cffc 100644 --- a/zellij-utils/src/plugin_api/event.rs +++ b/zellij-utils/src/plugin_api/event.rs @@ -14,6 +14,7 @@ pub use super::generated_api::api::{ key::Key as ProtobufKey, style::Style as ProtobufStyle, }; +#[allow(hidden_glob_reexports)] use crate::data::{ CopyDestination, Event, EventType, FileMetadata, InputMode, Key, LayoutInfo, ModeInfo, Mouse, PaneInfo, PaneManifest, PermissionStatus, PluginCapabilities, SessionInfo, Style, TabInfo, |