:: commit b51f2528d10e1aa84afb2ae691ad963682bca8ff

mintsuki <mintsuki@protonmail.com> — 2022-02-04 21:54

parents: 6e0fde5cfb

readline: Support C-[ae] for HOME and END

diff --git a/common/lib/readline.c b/common/lib/readline.c
index f13347b7..38fdc935 100644
--- a/common/lib/readline.c
+++ b/common/lib/readline.c
@@ -70,6 +70,8 @@ int getchar_internal(uint8_t scancode, uint8_t ascii, uint32_t shift_state) {
 
     if (shift_state & (GETCHAR_LCTRL | GETCHAR_RCTRL)) {
         switch (ascii) {
+        case 'a': return GETCHAR_HOME;
+        case 'e': return GETCHAR_END;
         case 'p': return GETCHAR_CURSOR_UP;
         case 'n': return GETCHAR_CURSOR_DOWN;
         case 'b': return GETCHAR_CURSOR_LEFT;
tab: 248 wrap: offon