Skip to content

Commit 539f817

Browse files
authored
Merge pull request #67 from lachlankrautz/feature/emacs-style-up-down
Add emacs style up/down shortcuts ctrl+n and ctrl+p
2 parents 7099721 + 1c50927 commit 539f817

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

src/Terminal/UnixTerminal.php

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -158,8 +158,10 @@ public function getKeyedInput()
158158
$map = [
159159
"\033[A" => 'up',
160160
"k" => 'up',
161+
"" => 'up', // emacs ^P
161162
"\033[B" => 'down',
162163
"j" => 'down',
164+
"" => 'down', //emacs ^N
163165
"\n" => 'enter',
164166
"\r" => 'enter',
165167
" " => 'enter',

0 commit comments

Comments
 (0)