microsoft / microsoft/edit

Alt key no longer works in tmux

Open
#390 0 comments 0 reactions 0 assignees View on GitHub
E-help-wanted
Dominant language
Rust
Stars
14.6k
Forks
734
Avg merge
8h 40m
Merged PRs (30d)
4

Description

So this is a weird environment. I have this line in my `.zshrc` (Ubuntu 24.04, gnome terminal, version 1.1.0):
```sh
if [[ -z "$TMUX" && ( -n "$DISPLAY" || -n "$SSH_CLIENT" ) ]]; then; tmux new -DAs0; exit; fi
```
And running the editor inside tmux seems to be causing #301.
Anyways, when trying to figure out when exactly that bug occurs, I discovered that the Alt key (for example Alt-f-x to quit) no longer works in a particular set of circumstances.
In my default tmux created on terminal startup by `.zshrc`, it *does* work.
In my regular terminal, it *does* work.
When I comment out my auto-tmux line and open tmux manually from a regular terminal, it does *not* work. I believe it was working before I updated `edit` to `v1.1.0`.

Contributor guide

Open the contributing guide

Research direction

Reproduce the Alt-key behavior in the three environments described: the .zshrc-created tmux session, a regular terminal, and tmux opened manually, using the editor at v1.1.0. Compare the failing manual-tmux case with the working cases; done means Alt-f-x and the other Alt-key commands work consistently in tmux.

Written by the indexing model from the issue text.

Assessment

Tech stack
rust, zsh
Domain
cli
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.