zellij-org / zellij

A terminal workspace with batteries included
https://zellij.dev
MIT License
20.67k stars 639 forks source link

Change command running in a pane #2147

Open devmatteini opened 1 year ago

devmatteini commented 1 year ago

As discussed in https://github.com/zellij-org/zellij/discussions/2137, a new command line option should be added to be able to change the running command in a pane.

The proposed implementation is:

zellij run --pane-id <pane_id> -- new-command
devmatteini commented 1 year ago

I'd like to help implement this feature if you want some help!

jameynakama commented 4 months ago

Is there any movement on this? I would really love this feature, and it would open endless possibilities for integrating with other apps.

In my use-case, I want to be able to open files from yazi (or whatever file explorer) in a specific pane.

---------------------------------------------------
|             |                                   |
|             |                                   |
|             |                                   |
|    yazi     |        zellij pane 2              |
|             |                                   |
|             |                                   |
|             |                                   |
---------------------------------------------------

Yazi could run something like this on opening a file: zellij run --pane-id 2 -- helix "$1".

This way, all the activity would be inside helix, meaning I wouldn't lose my buffers or panes or anything, since pane 2 would be dedicated.