vis
a vi-like editor based on Plan 9's structural regular expressions
git clone https://9o.is/git/vis.git
commit 5756da54ad6550b08e176d0b25c36710c6ab051b parent 893194c33fe9ea38b84fd43bcdfa4ed86d0028f7 Author: Marc André Tanner <mat@brain-dump.org> Date: Fri, 8 Dec 2017 10:54:20 +0100 vis: let <C-c> behave as <Escape> if only one selection exists This should allow the :-command prompt to be closed with <C-c><C-c> (from insert mode) or <C-c> (from normal mode). Fix #608 Diffstat:
| M | main.c | | | 2 | +- |
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/main.c b/main.c @@ -1484,7 +1484,7 @@ static const char *selections_remove_column(Vis *vis, const char *keys, const Ar if (column >= max) column = max - 1; if (view_selections_count(view) == 1) { - vis_mode_switch(vis, VIS_MODE_NORMAL); + vis_keys_feed(vis, "<Escape>"); return keys; }