Linux: Fig autocomplete doesn't integrate with IBus in tmux if a session does not already exist
Sanity checks
- [X] I have searched github.com/withfig/fig/issues and there are no duplicates of my issue
- [X] I have run
fig doctorin the affected terminal session - [X] I have run
fig restartand tested again (tell us if that fixed it)
Issue Details
Description:
Fedora 36 Workstation, Alacritty running Tmux.
On a fresh boot/restart/login, the first opened terminal window (Alacritty, oh-my-zsh plugin set to autolaunch tmux) has its Fig autocomplete window appear at the top left of my left monitor, a la "IBus not running".
My thought is that potentially the integration doesn't immediately happen until Alacritty launches a new tmux session, meaning figterm only runs after terminal/session have started.
This held true as I disabled the tmux autolaunch and rebooted. Alacritty doesn't launch figterm, nor does it open any autocomplete window if I run the command manually. When I launch tmux manually, the autocomplete window starts appearing at the top left until the terminal window is closed/reopened. It also works to run fig exit followed by fig (as fig restart isn't working (https://github.com/withfig/fig/issues/1763))
As this opens the GUI, which is a bit disruptive, my workaround is to autorun at login via an autostart script in KDE:
#! /usr/bin/zsh
# create a new detached tmux session with default name.
tmux new -ds0
Now whenever Alacritty autolaunches tmux, my terminal opens to a Fig autocomplete prompt that's working in the correct place.
PS. Interestingly, even though autocomplete isn't working if figterm is launched from Alacritty without tmux, if tmux is opened then existed, autocomplete works correctly in Alacritty-only from then on (until the machine is restarted).
Environment
fig-details:
- cli-version: 1.4.11
- desktop-version: 2.3.17
- figterm-version: 5.2.0
hardware-info:
- chip-id: AMD Ryzen 5 3600 6-Core Processor
- cores: 6
- mem: 15899.227 GB
os-info:
- kernel: 5.19.6-200.fc36.x86_64
- distro: "Fedora Linux 36 (Thirty Six)"
- distro-version: "36 (Thirty Six)"
environment:
- shell: /usr/bin/zsh
- terminal: <unknown>
- cwd: /home/kjkent
- exe-path: /usr/bin/fig
- install-method: unknown
- env-vars:
- DISPLAY: :0
- FIG_INTEGRATION_VERSION: 8
- FIG_PID: 3860
- FIG_TERM: 1
- FIG_TERM_TMUX: 1
- FIG_TERM_VERSION: 5.2.0
- GLFW_IM_MODULE: ibus
- GTK_IM_MODULE: ibus
- PATH: /usr/lib64/ccache:/home/kjkent/.nvm/versions/node/v16.16.0/bin:/usr/local/bin:/usr/bin:/bin:/usr/local/sbin:/usr/sbin:/sbin:/home/kjkent/.local/bin:/home/kjkent/.local/share/JetBrains/Toolbox/scripts:/home/kjkent/.fig/bin:/home/kjkent/.local/bin
- QT_IM_MODULE: ibus
- SHELL: /usr/bin/zsh
- TERM: tmux-256color
- TERM_SESSION_ID: e55143a6-fb10-46cc-bda2-98a7b456bc8a
- XDG_CURRENT_DESKTOP: KDE
- XDG_SESSION_DESKTOP: KDE
- XDG_SESSION_TYPE: x11
- XMODIFIERS: @im=ibus
I've recently tried to reinstall Fig on Linux and it seems it's moved back into a closed beta and I'm not invited to the party!
🥳🎉🤪 <--- the party... ...me ---> 😭
I'll leave this bug report and the others up and look forward to getting to try it out again someday!