In my .tmux.conf
I have this line:
bind r run "~/bin/tmux_renum"
But it doesn't work (it's supposed to renumber the tab windows - see http://brainscraps.wikia.com/wiki/Renumbering_tmux_Windows). It pops up the yellow status bar '~/bin/tmux_renum' returned 126.
I can't figure out what this means. Anyone seen this before?
I've been sure to exit out of tmux sessions completely, restarting tmux fresh to test.
If it matters, I'm using zsh too.
The tmux command run-shell
(abbreviated to run
in your configuration), passes the string to /bin/sh
†. Unless your script is running and exit
ing with code 126, then it is probably your /bin/sh
that is returning this exit code.
The high-number exit codes (126 and 127) are given by the shell when there is a problem executing the command. Specifically, (per POSIX.1) 126 usually means that the file was not executable.
Try this:
chmod +x ~/bin/tmux_renum
† Technically, it uses whatever _PATH_BSHELL is defined as, but this is almost always /bin/sh
on Unix-like systems.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With