small medium large xlarge

Back to: All Forums  tmux
29 Sep 2012, 07:43
d3vin h (4 posts)

description of what’s happening:

when minimizing a maximized pane, this message appears at bottom of terminal window: "Session not found: tmp"

# pane appears to return to same place as initial/previous session but the new tmp window (that was opened when the pane was first maximized) fails to close and appears in the list of windows (in the status bar at the bottom of tmux)

my hunch is kill-window -t tmp (in the below .tmux.conf code) is where things break. since executing a command in the tmp window appears to rename the window, kill-window -t tmp won’t work.

so my question is: how could i alter .tmux.conf to prevent this from happening?

steps to recreate bug:

(note: you would need to have modified .tmux.conf for these commands to work)

start tmux and create session w/ at least two panes

# maximize one pane using [prefix] + [up] # execute a shell command in maximized pane (1) # minimize pane using [prefix] + [down]

(1) if pane is maximized and minimized w/out executing a command in the shell this problem does not appear to occur. i.e. if you’re editing a file in a pane, then maximize that pane, and only edit/save the file (w/out exiting and then executing another command), then minimize – the bug doesn’t occur.

30s youtube clip showing what happens:

code that might be causing the error (from ~/.tmux.conf):

unbind Up 
bind Up new-window -d -n tmp \; swap-pane -s tmp.0 \; select-window -t tmp 
unbind Down 
bind Down last-window \; swap-pane -s tmp.0 \; kill-window -t tmp

also posted to SO:

feel free to let me know if i need to clarify or provide other information. thx!

29 Sep 2012, 09:01
d3vin h (4 posts)

thanks to a helpful #tmux irc’er this question is solved.

the solution is to add set-window-option -g allow-rename off to ~/.tmux.conf

this works b/c tmp doesn’t get renamed so kill-window -t tmp can properly execute.