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

fzf-tmux and tmuxifier load-session #93

Open
amiorin opened this issue Aug 26, 2023 · 2 comments
Open

fzf-tmux and tmuxifier load-session #93

amiorin opened this issue Aug 26, 2023 · 2 comments

Comments

@amiorin
Copy link

amiorin commented Aug 26, 2023

I have created a popup in tmux to switch session faster but it doesn't work as expected.

bind-key P run-shell "tmuxifier ls | fzf-tmux -p | xargs tmuxifier load-session"

Creating the session for the first time doesn't switch client. After the session is created, switch client works.
How can I debug the problem myself?

tmux 3.3a
tmuxifier 0.13.0
fish, version 3.6.1

@amiorin
Copy link
Author

amiorin commented Aug 27, 2023

There is a workaround. Create a script instead of the inline commands.

#! /usr/bin/env bash

set -x

session=$(tmuxifier ls | fzf-tmux -p)
tmuxifier load-session $session
tmux switch-client -t $session

@vendamere
Copy link

This worked for me.

bind-key P run-shell "tmuxifier ls | fzf-tmux -p | xargs -I % sh -c 'tmuxifier s %; tmux switch-client -t %;'"

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

2 participants