ervandew / screen

Simulate a split shell in vim using gnu screen or tmux
202 stars 31 forks source link

Finding screenshell window fails (tmux) #7

Closed mathstuf closed 12 years ago

mathstuf commented 13 years ago

I have my window-status-format to be '#I#F:#T-#W'. The rename-window command only sets the #W part and the search for the screenshell command fails.

Ideally, the pane should be stored using the session:window.pane address, but panes can be moved and even this isn't fool-proof. However the current solution can find the wrong pane if there is more than one window named 'screenshell'.

I've been poking it trying to get it to work without success so far.

ervandew commented 13 years ago

I just wanted to leave a comment letting you know I'm not ignoring this issue, I just don't know tmux well enough to come up with a good solution currently. Let me know if you find a suitable way to address the problem, even if it's just a less broken solution like the window pane address one you mentioned.

mathstuf commented 13 years ago

Yeah, I'm not sure of how to do this. To my knowledge you can't ask tmux 'what pane am I in?'. Even if you could, you can't guarantee it will stay the same because of the 'move-window' command (and other similar ones). If tmux had uuid's for each pane (injected into the environment?), that would work better.

mathstuf commented 13 years ago

Support for asking "What pane did I just create?" is in tmux HEAD. I started trying to get support into the plugin but hit a few issues. Relevant thread for the feature:

http://sourceforge.net/mailarchive/forum.php?thread_name=20101112080553.GA10902%40yelena.nicm.ath.cx&forum_name=tmux-users

guns commented 13 years ago

I've pushed an implementation for review at https://github.com/ervandew/screen/pull/10

ervandew commented 12 years ago

Closing since ervandew/screen#10 was merged in a while ago.