Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

bug: LaunchOrFocusPlugin creates new plugin instances when using plugin aliases #3409

Open
cristiand391 opened this issue Jun 9, 2024 · 0 comments

Comments

@cristiand391
Copy link
Contributor

cristiand391 commented Jun 9, 2024

2. Issues with the Zellij UI / behavior / crash

Issue description

both the CLI action launch-or-focus-plugin and keybind action LaunchOrFocusPlugin create a new plugin instance instead of focusing on the existing one when using plugin aliases.

Workaround: use file schema URL

Minimal reproduction

  1. download zj-quit and set up an alias for it:
plugins {
  zj-quit location="file:/path/to/zj-quit.wasm"
}
  1. start zellij and launch it from the CLI with the launch-or-focus-plugin action using the plugin alias:
zellij action launch-or-focus-plugin --floating zj-quit

press Esc to make it hide itself:
https://github.com/cristiand391/zj-quit/blob/1ab13ff06af29215bba33ed03b116ef407acc8c1/src/main.rs#L40

repeat that 3 times and then open the session-manager and check the panes in the current tab, you should see this:
image

note that there's 3 zj-quit panes instead of just 1.

now repeat step 2 but use the file schema URL:

zellij action launch-or-focus-plugin --floating "file:/path/to/zj-quit.wasm"

check the session-manager again, only 1 zj-quit instance is open.

Other relevant information

I noticed this first when using the keybind action, doesn't seem to affect the zellij: schema.

zellij --version: zellij 0.40.1

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant