summaryrefslogtreecommitdiff
path: root/libbb/read.c
diff options
context:
space:
mode:
authorRon Yorston2021-04-06 16:48:07 +0100
committerDenys Vlasenko2021-04-11 00:18:55 +0200
commita54450248b063afd96530821020872bfc9ec9997 (patch)
tree37d9b739a45474ab8d8865af1fc965f8c582b731 /libbb/read.c
parentfe76569daa88429276e72dc0c51c0b58d275aee7 (diff)
downloadbusybox-a54450248b063afd96530821020872bfc9ec9997.zip
busybox-a54450248b063afd96530821020872bfc9ec9997.tar.gz
vi: allow the '.' command to have a repetition count
The '.' command repeats the last text change. When it has a repetition count replay the change the number of times requested. Update the stored count if it changes. For example, 3dw deletes 3 words . deletes another 3 words 2. deletes 2 words and changes the stored count . deletes 2 words function old new delta do_cmd 4746 4781 +35 .rodata 105133 105138 +5 edit_file 887 849 -38 ------------------------------------------------------------------------------ (add/remove: 0/0 grow/shrink: 2/1 up/down: 40/-38) Total: 2 bytes v2: Change implementation to include repetition count in string. Otherwise repeating 'r' doesn't work properly. Signed-off-by: Ron Yorston <rmy@pobox.com> Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
Diffstat (limited to 'libbb/read.c')
0 files changed, 0 insertions, 0 deletions