sainnhe / tmux-fzf

Use fzf to manage your tmux work environment!
MIT License
991 stars 53 forks source link

Show the current session/window/pane when switching #78

Closed FrostyX closed 8 months ago

FrostyX commented 9 months ago

For some reason, I cannot see the current session, window, and pane when switching. I am not sure whether it is a bug or a feature but it is IMHO very unpleasant.

If this is a feature, can we have have a config variable to optionally show current thing in the fzf items, please?

sainnhe commented 9 months ago

Do you mean preview the content? It’s already supported and enable by default.

FrostyX commented 9 months ago

Thank you for the reply @sainnhe, It will be probably the easiest to show you.

Here, you can see the list of all my Tmux sessions. The currently attached session is named fedora-review.

Screenshot_2024-03-07_15-05-22

Here I am running ~/.tmux/plugins/tmux-fzf/scripts/session.sh switch

Screenshot_2024-03-07_15-06-05

As you can see, all the sessions are listed except for the fedora-review.

sainnhe commented 9 months ago

It’s expected. Since the action is “switch”, the current session is excluded in the list.

FrostyX commented 9 months ago

Oh, so it is a feature. Can we optionally have the current session/window/etc included in the list, please? This wouldn't be unprecedented ... FZF plugin in Vim also lists the current buffer among the possible buffers to switch. Same for narrowing frameworks in Emacs, etc.

sainnhe commented 8 months ago

PR is welcome.

FrostyX commented 8 months ago

PR is welcome.

Perfect, thank you :-) I submitted PR #79