Option key does not work as Meta in Tmux
I am using Mac OSX Lion. I have checked "Use Option key as Meta" in Terminal preferences. Although the Option key seems to work fine as Meta in Bash, when I use it in Tmux (over SSH) it does not work properly. I am trying to use TMUX shortcuts like ^b M-1
b M-2
etc. I can get these with the ESC key but not the Option key.
macos osx-lion tmux
add a comment |
I am using Mac OSX Lion. I have checked "Use Option key as Meta" in Terminal preferences. Although the Option key seems to work fine as Meta in Bash, when I use it in Tmux (over SSH) it does not work properly. I am trying to use TMUX shortcuts like ^b M-1
b M-2
etc. I can get these with the ESC key but not the Option key.
macos osx-lion tmux
^b Space
with cycle through the various layouts
– caspyin
Mar 22 '14 at 14:03
add a comment |
I am using Mac OSX Lion. I have checked "Use Option key as Meta" in Terminal preferences. Although the Option key seems to work fine as Meta in Bash, when I use it in Tmux (over SSH) it does not work properly. I am trying to use TMUX shortcuts like ^b M-1
b M-2
etc. I can get these with the ESC key but not the Option key.
macos osx-lion tmux
I am using Mac OSX Lion. I have checked "Use Option key as Meta" in Terminal preferences. Although the Option key seems to work fine as Meta in Bash, when I use it in Tmux (over SSH) it does not work properly. I am trying to use TMUX shortcuts like ^b M-1
b M-2
etc. I can get these with the ESC key but not the Option key.
macos osx-lion tmux
macos osx-lion tmux
asked Sep 25 '13 at 5:07
PhaniPhani
273137
273137
^b Space
with cycle through the various layouts
– caspyin
Mar 22 '14 at 14:03
add a comment |
^b Space
with cycle through the various layouts
– caspyin
Mar 22 '14 at 14:03
^b Space
with cycle through the various layouts– caspyin
Mar 22 '14 at 14:03
^b Space
with cycle through the various layouts– caspyin
Mar 22 '14 at 14:03
add a comment |
4 Answers
4
active
oldest
votes
I would suggest using iTerm2 instead of the default Terminal.app, as it is better for many reasons.
Specifically, you would be interested in iTerm2's options to map left/right option as "+Esc", which works much better than trying to have it emulate Meta for every purpose I can think of or have tried.
This setting is located under:
- Preferences
- Profiles
- [select a profile]
- Keys
- [select a profile]
- Profiles
1
I was looking for a reason to move to iTerm2 and here I have it. Thanks!!
– Phani
Sep 27 '13 at 17:32
12
May I ask why you choose to set option to "+Esc" and not to "Meta" when it sounds like you're trying to use Meta-keys? What is the difference / why is "+Esc" better? Thanks!
– NHDaly
Mar 1 '14 at 19:15
add a comment |
For other folks who find their way here via their favorite search engine, I was able to solve this problem by simply going to Preferences -> Profiles -> Keyboard and checking "Use Option as Meta key" for the terminal profile I'm using.
I'm running weechat
under tmux
, and default key bindings make heavy use of the meta
key.
you save my day!
– zx1986
Feb 11 at 13:51
add a comment |
I had the same problem and none of the answers provided here worked. That is, I too had the iTerm2 [Option]
key remapped to [+Esc]
(aka. "fallback"-[META]
) in my "Preferences -> Profiles -> Keyboard", as described in the other answers, but still could not change my tmux pane layout with [CTRL]-[b]
, [+Esc/META]-[DIGIT]
.
Then I found that under "Preferences -> Keys", there is a "Navigation Shortcuts" where [Option]
+ (any) [DIGIT]
is mapped to "switch split panes" (remember [Option]
is remapped to [+Esc]
, so that's a clear collision). Therefore, after un-setting that (to an empty key value), I finally can again comfortably resize my tmux panes with [CTRL]-[b]
, [+Esc/META]-[DIGIT]
(instead of having to use [CTRL]-[b]
, (the real) [Esc]
, and then the desired layout [DIGIT]
).
add a comment |
In my .zshrc
I usually have the following set:
bindkey '^[[1;9C' forward-word
bindkey '^[[1;9D' backward-word
Within tmux sessions, I had to additionally include
bindkey '^[[1;3C' forward-word
bindkey '^[[1;3D' backward-word
You can figure out these codes by running read
in a session, then pressing the keyboard shortcuts, e.g. Alt←.
My keys are set as follows in iTerm2:
add a comment |
Your Answer
StackExchange.ready(function() {
var channelOptions = {
tags: "".split(" "),
id: "3"
};
initTagRenderer("".split(" "), "".split(" "), channelOptions);
StackExchange.using("externalEditor", function() {
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled) {
StackExchange.using("snippets", function() {
createEditor();
});
}
else {
createEditor();
}
});
function createEditor() {
StackExchange.prepareEditor({
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: true,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
imageUploader: {
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
},
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
});
}
});
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fsuperuser.com%2fquestions%2f649960%2foption-key-does-not-work-as-meta-in-tmux%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
4 Answers
4
active
oldest
votes
4 Answers
4
active
oldest
votes
active
oldest
votes
active
oldest
votes
I would suggest using iTerm2 instead of the default Terminal.app, as it is better for many reasons.
Specifically, you would be interested in iTerm2's options to map left/right option as "+Esc", which works much better than trying to have it emulate Meta for every purpose I can think of or have tried.
This setting is located under:
- Preferences
- Profiles
- [select a profile]
- Keys
- [select a profile]
- Profiles
1
I was looking for a reason to move to iTerm2 and here I have it. Thanks!!
– Phani
Sep 27 '13 at 17:32
12
May I ask why you choose to set option to "+Esc" and not to "Meta" when it sounds like you're trying to use Meta-keys? What is the difference / why is "+Esc" better? Thanks!
– NHDaly
Mar 1 '14 at 19:15
add a comment |
I would suggest using iTerm2 instead of the default Terminal.app, as it is better for many reasons.
Specifically, you would be interested in iTerm2's options to map left/right option as "+Esc", which works much better than trying to have it emulate Meta for every purpose I can think of or have tried.
This setting is located under:
- Preferences
- Profiles
- [select a profile]
- Keys
- [select a profile]
- Profiles
1
I was looking for a reason to move to iTerm2 and here I have it. Thanks!!
– Phani
Sep 27 '13 at 17:32
12
May I ask why you choose to set option to "+Esc" and not to "Meta" when it sounds like you're trying to use Meta-keys? What is the difference / why is "+Esc" better? Thanks!
– NHDaly
Mar 1 '14 at 19:15
add a comment |
I would suggest using iTerm2 instead of the default Terminal.app, as it is better for many reasons.
Specifically, you would be interested in iTerm2's options to map left/right option as "+Esc", which works much better than trying to have it emulate Meta for every purpose I can think of or have tried.
This setting is located under:
- Preferences
- Profiles
- [select a profile]
- Keys
- [select a profile]
- Profiles
I would suggest using iTerm2 instead of the default Terminal.app, as it is better for many reasons.
Specifically, you would be interested in iTerm2's options to map left/right option as "+Esc", which works much better than trying to have it emulate Meta for every purpose I can think of or have tried.
This setting is located under:
- Preferences
- Profiles
- [select a profile]
- Keys
- [select a profile]
- Profiles
answered Sep 27 '13 at 2:34
demuredemure
4,01711526
4,01711526
1
I was looking for a reason to move to iTerm2 and here I have it. Thanks!!
– Phani
Sep 27 '13 at 17:32
12
May I ask why you choose to set option to "+Esc" and not to "Meta" when it sounds like you're trying to use Meta-keys? What is the difference / why is "+Esc" better? Thanks!
– NHDaly
Mar 1 '14 at 19:15
add a comment |
1
I was looking for a reason to move to iTerm2 and here I have it. Thanks!!
– Phani
Sep 27 '13 at 17:32
12
May I ask why you choose to set option to "+Esc" and not to "Meta" when it sounds like you're trying to use Meta-keys? What is the difference / why is "+Esc" better? Thanks!
– NHDaly
Mar 1 '14 at 19:15
1
1
I was looking for a reason to move to iTerm2 and here I have it. Thanks!!
– Phani
Sep 27 '13 at 17:32
I was looking for a reason to move to iTerm2 and here I have it. Thanks!!
– Phani
Sep 27 '13 at 17:32
12
12
May I ask why you choose to set option to "+Esc" and not to "Meta" when it sounds like you're trying to use Meta-keys? What is the difference / why is "+Esc" better? Thanks!
– NHDaly
Mar 1 '14 at 19:15
May I ask why you choose to set option to "+Esc" and not to "Meta" when it sounds like you're trying to use Meta-keys? What is the difference / why is "+Esc" better? Thanks!
– NHDaly
Mar 1 '14 at 19:15
add a comment |
For other folks who find their way here via their favorite search engine, I was able to solve this problem by simply going to Preferences -> Profiles -> Keyboard and checking "Use Option as Meta key" for the terminal profile I'm using.
I'm running weechat
under tmux
, and default key bindings make heavy use of the meta
key.
you save my day!
– zx1986
Feb 11 at 13:51
add a comment |
For other folks who find their way here via their favorite search engine, I was able to solve this problem by simply going to Preferences -> Profiles -> Keyboard and checking "Use Option as Meta key" for the terminal profile I'm using.
I'm running weechat
under tmux
, and default key bindings make heavy use of the meta
key.
you save my day!
– zx1986
Feb 11 at 13:51
add a comment |
For other folks who find their way here via their favorite search engine, I was able to solve this problem by simply going to Preferences -> Profiles -> Keyboard and checking "Use Option as Meta key" for the terminal profile I'm using.
I'm running weechat
under tmux
, and default key bindings make heavy use of the meta
key.
For other folks who find their way here via their favorite search engine, I was able to solve this problem by simply going to Preferences -> Profiles -> Keyboard and checking "Use Option as Meta key" for the terminal profile I'm using.
I'm running weechat
under tmux
, and default key bindings make heavy use of the meta
key.
edited Apr 23 '16 at 14:37
answered Aug 27 '15 at 1:37
larskslarsks
2,8821521
2,8821521
you save my day!
– zx1986
Feb 11 at 13:51
add a comment |
you save my day!
– zx1986
Feb 11 at 13:51
you save my day!
– zx1986
Feb 11 at 13:51
you save my day!
– zx1986
Feb 11 at 13:51
add a comment |
I had the same problem and none of the answers provided here worked. That is, I too had the iTerm2 [Option]
key remapped to [+Esc]
(aka. "fallback"-[META]
) in my "Preferences -> Profiles -> Keyboard", as described in the other answers, but still could not change my tmux pane layout with [CTRL]-[b]
, [+Esc/META]-[DIGIT]
.
Then I found that under "Preferences -> Keys", there is a "Navigation Shortcuts" where [Option]
+ (any) [DIGIT]
is mapped to "switch split panes" (remember [Option]
is remapped to [+Esc]
, so that's a clear collision). Therefore, after un-setting that (to an empty key value), I finally can again comfortably resize my tmux panes with [CTRL]-[b]
, [+Esc/META]-[DIGIT]
(instead of having to use [CTRL]-[b]
, (the real) [Esc]
, and then the desired layout [DIGIT]
).
add a comment |
I had the same problem and none of the answers provided here worked. That is, I too had the iTerm2 [Option]
key remapped to [+Esc]
(aka. "fallback"-[META]
) in my "Preferences -> Profiles -> Keyboard", as described in the other answers, but still could not change my tmux pane layout with [CTRL]-[b]
, [+Esc/META]-[DIGIT]
.
Then I found that under "Preferences -> Keys", there is a "Navigation Shortcuts" where [Option]
+ (any) [DIGIT]
is mapped to "switch split panes" (remember [Option]
is remapped to [+Esc]
, so that's a clear collision). Therefore, after un-setting that (to an empty key value), I finally can again comfortably resize my tmux panes with [CTRL]-[b]
, [+Esc/META]-[DIGIT]
(instead of having to use [CTRL]-[b]
, (the real) [Esc]
, and then the desired layout [DIGIT]
).
add a comment |
I had the same problem and none of the answers provided here worked. That is, I too had the iTerm2 [Option]
key remapped to [+Esc]
(aka. "fallback"-[META]
) in my "Preferences -> Profiles -> Keyboard", as described in the other answers, but still could not change my tmux pane layout with [CTRL]-[b]
, [+Esc/META]-[DIGIT]
.
Then I found that under "Preferences -> Keys", there is a "Navigation Shortcuts" where [Option]
+ (any) [DIGIT]
is mapped to "switch split panes" (remember [Option]
is remapped to [+Esc]
, so that's a clear collision). Therefore, after un-setting that (to an empty key value), I finally can again comfortably resize my tmux panes with [CTRL]-[b]
, [+Esc/META]-[DIGIT]
(instead of having to use [CTRL]-[b]
, (the real) [Esc]
, and then the desired layout [DIGIT]
).
I had the same problem and none of the answers provided here worked. That is, I too had the iTerm2 [Option]
key remapped to [+Esc]
(aka. "fallback"-[META]
) in my "Preferences -> Profiles -> Keyboard", as described in the other answers, but still could not change my tmux pane layout with [CTRL]-[b]
, [+Esc/META]-[DIGIT]
.
Then I found that under "Preferences -> Keys", there is a "Navigation Shortcuts" where [Option]
+ (any) [DIGIT]
is mapped to "switch split panes" (remember [Option]
is remapped to [+Esc]
, so that's a clear collision). Therefore, after un-setting that (to an empty key value), I finally can again comfortably resize my tmux panes with [CTRL]-[b]
, [+Esc/META]-[DIGIT]
(instead of having to use [CTRL]-[b]
, (the real) [Esc]
, and then the desired layout [DIGIT]
).
edited Jun 15 '17 at 10:14
answered Jun 15 '17 at 10:09
fnlfnl
1314
1314
add a comment |
add a comment |
In my .zshrc
I usually have the following set:
bindkey '^[[1;9C' forward-word
bindkey '^[[1;9D' backward-word
Within tmux sessions, I had to additionally include
bindkey '^[[1;3C' forward-word
bindkey '^[[1;3D' backward-word
You can figure out these codes by running read
in a session, then pressing the keyboard shortcuts, e.g. Alt←.
My keys are set as follows in iTerm2:
add a comment |
In my .zshrc
I usually have the following set:
bindkey '^[[1;9C' forward-word
bindkey '^[[1;9D' backward-word
Within tmux sessions, I had to additionally include
bindkey '^[[1;3C' forward-word
bindkey '^[[1;3D' backward-word
You can figure out these codes by running read
in a session, then pressing the keyboard shortcuts, e.g. Alt←.
My keys are set as follows in iTerm2:
add a comment |
In my .zshrc
I usually have the following set:
bindkey '^[[1;9C' forward-word
bindkey '^[[1;9D' backward-word
Within tmux sessions, I had to additionally include
bindkey '^[[1;3C' forward-word
bindkey '^[[1;3D' backward-word
You can figure out these codes by running read
in a session, then pressing the keyboard shortcuts, e.g. Alt←.
My keys are set as follows in iTerm2:
In my .zshrc
I usually have the following set:
bindkey '^[[1;9C' forward-word
bindkey '^[[1;9D' backward-word
Within tmux sessions, I had to additionally include
bindkey '^[[1;3C' forward-word
bindkey '^[[1;3D' backward-word
You can figure out these codes by running read
in a session, then pressing the keyboard shortcuts, e.g. Alt←.
My keys are set as follows in iTerm2:
answered Feb 7 at 13:48
slhckslhck
162k47448471
162k47448471
add a comment |
add a comment |
Thanks for contributing an answer to Super User!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fsuperuser.com%2fquestions%2f649960%2foption-key-does-not-work-as-meta-in-tmux%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
^b Space
with cycle through the various layouts– caspyin
Mar 22 '14 at 14:03