diff options
| -rw-r--r-- | README.md | 3 | ||||
| -rw-r--r-- | vis.c | 7 |
2 files changed, 9 insertions, 1 deletions
@@ -263,7 +263,8 @@ Operators can be forced to work line wise by specifying `V`. The general purpose registers `[a-z]` can be used to record macros. Use one of `[A-Z]` to append to an existing macro. `q` starts a recording, - `@` plays it back. `@@` refers to the least recently recorded macro. + `@` plays it back. `@@` refers to the least recently recorded macro. + `@:` repeats the last :-command. `@/` is equivalent to `n` in normal mode. ### Command line prompt @@ -976,6 +976,13 @@ static void macro_replay(Vis *vis, const Macro *macro) { } bool vis_macro_replay(Vis *vis, enum VisRegister id) { + if (id == VIS_REG_SEARCH) + return vis_motion(vis, VIS_MOVE_SEARCH_NEXT); + if (id == VIS_REG_COMMAND) { + const char *cmd = register_get(vis, &vis->registers[id], NULL); + return vis_cmd(vis, cmd); + } + Macro *macro = macro_get(vis, id); if (!macro || macro == vis->recording) return false; |
