Skip to content

Conversation

peikk0
Copy link
Contributor

@peikk0 peikk0 commented Apr 18, 2025

tmux popup doesn't work and immediately returns instead when spawn inside one (tmux popup tmux popup echo foo results in an empty popup). For that reason, fzf --tmux doesn't work when executed inside a tmux popup, for example:

FZF_DEFAULT_OPTS=--tmux tmux popup 'find . | fzf'

And executing fzf --tmux inside fzf --tmux (as forgit does, which was how I ran into this issue) also doesn't work, for example:

find . -type d | FZF_DEFAULT_OPTS=--tmux fzf --bind="enter:execute(find {} -type f | fzf | xargs less)"

A popup can be detected by the absence of the TMUX_PANE environment variable, so we can simply disable the --tmux mode when it is absent. And it also must be excluded for the exports in runProxy() so that the popup can also be detected properly by child processes.

@junegunn junegunn merged commit af8fe91 into junegunn:master Apr 18, 2025
@junegunn
Copy link
Owner

Thanks!

@peikk0 peikk0 deleted the fix-exec-inside-tmux-popup branch April 18, 2025 13:57
junegunn added a commit that referenced this pull request Apr 22, 2025
@dbzix
Copy link

dbzix commented Apr 23, 2025

Yesterday, I spent hours guessing which update in my system broke my beautiful popups in tmux.
Thanks for reverting this!

tmeijn pushed a commit to tmeijn/dotfiles that referenced this pull request Apr 26, 2025
This MR contains the following updates:

| Package | Update | Change |
|---|---|---|
| [junegunn/fzf](https://github.com/junegunn/fzf) | patch | `v0.61.2` -> `v0.61.3` |

MR created with the help of [el-capitano/tools/renovate-bot](https://gitlab.com/el-capitano/tools/renovate-bot).

**Proposed changes to behavior should be submitted there as MRs.**

---

### Release Notes

<details>
<summary>junegunn/fzf (junegunn/fzf)</summary>

### [`v0.61.3`](https://github.com/junegunn/fzf/releases/tag/v0.61.3): 0.61.3

[Compare Source](junegunn/fzf@v0.61.2...v0.61.3)

-   Reverted [#&#8203;4351](junegunn/fzf#4351) as it caused `tmux run-shell 'fzf --tmux'` to fail ([#&#8203;4559](https://github.com/junegunn/fzf/issues/4559) [#&#8203;4560](https://github.com/junegunn/fzf/issues/4560))
-   More environment variables for child processes ([#&#8203;4356](junegunn/fzf#4356))

</details>

---

### Configuration

📅 **Schedule**: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined).

🚦 **Automerge**: Enabled.

♻ **Rebasing**: Whenever MR is behind base branch, or you tick the rebase/retry checkbox.

🔕 **Ignore**: Close this MR and you won't be reminded about this update again.

---

 - [ ] <!-- rebase-check -->If you want to rebase/retry this MR, check this box

---

This MR has been generated by [Renovate Bot](https://github.com/renovatebot/renovate).
<!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzOS4yNTcuOCIsInVwZGF0ZWRJblZlciI6IjM5LjI1Ny44IiwidGFyZ2V0QnJhbmNoIjoibWFpbiIsImxhYmVscyI6WyJSZW5vdmF0ZSBCb3QiXX0=-->
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

Successfully merging this pull request may close these issues.

3 participants