luccahuguet / yazelix

Zellij and Yazi adding a File Tree to Helix & helix-friendly keybindigs for Zellij
151 stars 9 forks source link

Failed to check if the command running in the current pane is helix #17

Open lens0021 opened 2 weeks ago

lens0021 commented 2 weeks ago

https://github.com/luccahuguet/yazelix/blob/8a675729a29e7678fe1770c36eb12ddcb44d3e16/yazi/open_file.sh#L10 is always false for me.

When I tested, zellij action list-clients is:

CLIENT_ID ZELLIJ_PANE_ID RUNNING_COMMAND
1         terminal_1     hx /some/path -w /some/path

so

$ echo hx | grep -q "/hx$"; echo $?
1
$ echo hx | grep -q "hx$"; echo $?
0

for me.

luccahuguet commented 2 weeks ago

thanks, will look into it

luccahuguet commented 2 weeks ago

did it fail all times or only some times?

luccahuguet commented 2 weeks ago

was the helix pane next to the yazi pane?

to the right of the yazi pane?

lens0021 commented 2 weeks ago

Hm, here are reproduction steps:

git clone --depth 1 https://github.com/luccahuguet/yazelix.git
cd yazelix
zellij --config-dir zellij options --layout-dir zellij/layouts

Screencast from 2024-08-29 11-32-33.webm

did it fail all times or only some times?

sometimes it success, but I does not know when