kovidgoyal / kitty

Cross-platform, fast, feature-rich, GPU based terminal
https://sw.kovidgoyal.net/kitty/
GNU General Public License v3.0
23.87k stars 964 forks source link

Make `kitten transfer` work in tmux #7298

Closed Toorero closed 5 months ago

Toorero commented 5 months ago

Describe the bug Transferring files in a tmux session doesn't work for me, as the confirmation prompt to allow the transfer is never shown.

To Reproduce Steps to reproduce the behaviour:

  1. Connect to machine with kitten ssh foo@example.com
  2. Open a new tmux window with tmux
  3. Run kitten transfer foo bar
  4. Pane hangs forever with message Found 1 files and directories, requesting transfer permission…

Environment details

kitty 0.33.0 created by Kovid Goyal
Linux framework13 6.8.2-zen2-1-zen #1 ZEN SMP PREEMPT_DYNAMIC Thu, 28 Mar 2024 17:06:20 +0000 x86_64
Arch Linux 6.8.2-zen2-1-zen (/dev/tty)

DISTRIB_ID="Arch"
DISTRIB_RELEASE="rolling"
DISTRIB_DESCRIPTION="Arch Linux"
Running under: Wayland
Frozen: False
Paths:
  kitty: /usr/bin/kitty
  base dir: /usr/lib/kitty
  extensions dir: /usr/lib/kitty/kitty
  system shell: /bin/zsh
Loaded config files:
  /home/foo/.config/kitty/kitty.conf

Config options different from defaults:
background_opacity      0.98
bold_font               FiraCode Nerd Font SemBd
enable_audio_bell       False
font_family             FiraCode Nerd Font Reg
font_features:
{'FiraCodeNF-Reg': ('+cv10', '+ss05', '+ss03', '+zero')}
inactive_text_alpha     0.5
initial_window_height   (40, 'cells')
initial_window_width    (120, 'cells')
remember_window_size    False
url_style               2
visual_bell_duration    0.3
wayland_titlebar_color  589639170
Added shortcuts:
    ctrl+c →  copy_or_interrupt
    f1 →  new_window_with_cwd
Colors:
    active_border_color     #31748f   
    active_tab_background   #26233a   
    active_tab_foreground   #e0def4   
    background              #191724   
    color0                  #26233a   
    color1                  #eb6f92   
    color10                 #31748f   
    color11                 #f6c177   
    color12                 #9ccfd8   
    color13                 #c4a7e7   
    color14                 #ebbcba   
    color15                 #e0def4   
    color2                  #31748f   
    color3                  #f6c177   
    color4                  #9ccfd8   
    color5                  #c4a7e7   
    color6                  #ebbcba   
    color7                  #e0def4   
    color8                  #6e6a86   
    color9                  #eb6f92   
    cursor                  #524f67   
    cursor_text_color       #e0def4   
    foreground              #e0def4   
    inactive_border_color   #403d52   
    inactive_tab_background #191724   
    inactive_tab_foreground #6e6a86   
    selection_background    #403d52   
    selection_foreground    #e0def4   
    url_color               #c4a7e7   
    visual_bell_color       #494c55   

Important environment variables seen by the kitty process:
    PATH                                /home/foo/.local/share/cargo/bin:/home/foo/.local/share/perl5/bin:/usr/lib/go/bin:/home/foo/.local/share/go/bin:/home/foo/.local/bin:/usr/local/bin:/usr/bin:/usr/local/sbin:/var/lib/flatpak/exports/bin:/usr/lib/jvm/default/bin:/usr/bin/site_perl:/usr/bin/vendor_perl:/usr/bin/core_perl:/usr/lib/rustup/bin
    LANG                                de_DE.UTF-8
    EDITOR                              nvim
    SHELL                               /bin/zsh
    DISPLAY                             :0
    WAYLAND_DISPLAY                     wayland-0
    USER                                foo
    XDG_DATA_DIRS                       /home/foo/.local/share/flatpak/exports/share:/var/lib/flatpak/exports/share:/usr/local/share/:/usr/share/
    XDG_RUNTIME_DIR                     /run/user/1000
    XDG_CACHE_HOME                      /home/foo/.cache
    XDG_CONFIG_HOME                     /home/foo/.config
    XDG_CURRENT_DESKTOP                 GNOME
    XDG_DATA_HOME                       /home/foo/.local/share
    XDG_DESKTOP_DIR                     /home/foo/Schreibtisch
    XDG_DOCUMENTS_DIR                   /home/foo/Dokumente
    XDG_DOWNLOAD_DIR                    /home/foo/Downloads
    XDG_MENU_PREFIX                     gnome-
    XDG_MUSIC_DIR                       /home/foo/Musik
    XDG_PICTURES_DIR                    /home/foo/Bilder
    XDG_PUBLICSHARE_DIR                 /home/foo/Öffentlich
    XDG_SESSION_CLASS                   user
    XDG_SESSION_DESKTOP                 gnome
    XDG_SESSION_TYPE                    wayland
    XDG_STATE_HOME                      /home/foo/.local/state
    XDG_TEMPLATES_DIR                   /home/foo/Vorlagen
    XDG_VIDEOS_DIR                      /home/foo/Videos

Additional context Reproducible with kitten --config NONE. Haven't tried to reproduce it with a fresh environment and fresh tmux on the remote system yet. I would only go in that hustle if it's not reproducible by others.

kovidgoyal commented 5 months ago

https://sw.kovidgoyal.net/kitty/faq/#i-am-using-tmux-and-have-a-problem