You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When calling open_terminal() from a plugin, the newly created terminal behaves differently than one created via e.g. Alt+n
The title of the pane is not e.g. Pane #2, but /bin/bash (or whatever is the default shell)
PaneInfo has terminal_command set to Some("/bin/bash") instead of None, marking it as a command pane
/// If this is a command pane, this will show the stringified version of the command and its
/// arguments
pub terminal_command: Option<String>,
Minimal reproduction
use zellij_tile::prelude::*;
use std::collections::BTreeMap;
#[derive(Default)]
struct State {}
register_plugin!(State);
impl ZellijPlugin for State {
fn load(&mut self, _configuration: BTreeMap<String, String>) {
request_permission(&[
PermissionType::OpenTerminalsOrPlugins,
PermissionType::ReadApplicationState,
]);
}
fn update(&mut self, _event: Event) -> bool {
open_terminal("./");
close_self();
false
}
fn render(&mut self, _rows: usize, _cols: usize) {}
}
Run: zellij plugin --skip-plugin-cache -- file:/path/to/rust-plugin-example/target/wasm32-wasi/debug/rust-plugin-example.wasm
This should (after granting permissions) simply open a new pane with the described behavior.
Issue description
When calling
open_terminal()
from a plugin, the newly created terminal behaves differently than one created via e.g.Alt+n
Pane #2
, but/bin/bash
(or whatever is the default shell)PaneInfo
hasterminal_command
set toSome("/bin/bash")
instead ofNone
, marking it as a command paneMinimal reproduction
Run:
zellij plugin --skip-plugin-cache -- file:/path/to/rust-plugin-example/target/wasm32-wasi/debug/rust-plugin-example.wasm
This should (after granting permissions) simply open a new pane with the described behavior.
Other relevant information
This was likely introduced with this PR: #3296
The text was updated successfully, but these errors were encountered: