Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
O
oh-my-zsh
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
JIRA
JIRA
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
github
oh-my-zsh
Commits
308b2314
Unverified
Commit
308b2314
authored
May 28, 2021
by
Marc Cornellà
Committed by
GitHub
May 28, 2021
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix(dirhistory): fix ALT+Left/Right key bindings for iTerm2 (#9940)
parent
7ab15bee
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
12 additions
and
3 deletions
+12
-3
dirhistory.plugin.zsh
plugins/dirhistory/dirhistory.plugin.zsh
+12
-3
No files found.
plugins/dirhistory/dirhistory.plugin.zsh
View file @
308b2314
...
...
@@ -124,10 +124,14 @@ zle -N dirhistory_zle_dirhistory_back
# xterm in normal mode
bindkey
"
\e
[3D"
dirhistory_zle_dirhistory_back
bindkey
"
\e
[1;3D"
dirhistory_zle_dirhistory_back
#
Mac teminal (alt+left/right)
if
[[
"
$TERM_PROGRAM
"
==
"Apple_Terminal"
||
"
$TERM_PROGRAM
"
==
"iTerm.app"
]]
;
then
#
Terminal.app
if
[[
"
$TERM_PROGRAM
"
==
"Apple_Terminal"
]]
;
then
bindkey
"^[b"
dirhistory_zle_dirhistory_back
fi
# iTerm2
if
[[
"
$TERM_PROGRAM
"
==
"iTerm.app"
]]
;
then
bindkey
"^[^[[D"
dirhistory_zle_dirhistory_back
fi
# Putty:
bindkey
"
\e\e
[D"
dirhistory_zle_dirhistory_back
# GNU screen:
...
...
@@ -136,9 +140,14 @@ bindkey "\eO3D" dirhistory_zle_dirhistory_back
zle
-N
dirhistory_zle_dirhistory_future
bindkey
"
\e
[3C"
dirhistory_zle_dirhistory_future
bindkey
"
\e
[1;3C"
dirhistory_zle_dirhistory_future
if
[[
"
$TERM_PROGRAM
"
==
"Apple_Terminal"
||
"
$TERM_PROGRAM
"
==
"iTerm.app"
]]
;
then
# Terminal.app
if
[[
"
$TERM_PROGRAM
"
==
"Apple_Terminal"
]]
;
then
bindkey
"^[f"
dirhistory_zle_dirhistory_future
fi
# iTerm2
if
[[
"
$TERM_PROGRAM
"
==
"iTerm.app"
]]
;
then
bindkey
"^[^[[C"
dirhistory_zle_dirhistory_future
fi
bindkey
"
\e\e
[C"
dirhistory_zle_dirhistory_future
bindkey
"
\e
O3C"
dirhistory_zle_dirhistory_future
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment