[Toybox] [PATCH] vi: mem_block/piece_table part 2

Jarno Mäkipää jmakip87 at gmail.com
Sun Jan 19 00:39:52 PST 2020


After this patch functionality should be around the same as with
linelist

Implement more proper file write:
file is saved to .swp, blocks are unloaded, file permissions are copied,
and atomic rename is called, block is reloaded
chmod some defaults(rw-r--r--) if original file could not be fstat (does
not exist)

Reimplement simple search /string

fix w, b, e moves
fix 1G
fix moving cur_right on zalgo text

Count line numbers for drawing purposes (placeholder needs rewrite)
(If file is too big, gives up) this needs rework.

cleanup Make function for searching offset slice
cleanup Make local functions static
---
 toys/pending/vi.c | 361 ++++++++++++++++++++++++++++------------------
 1 file changed, 218 insertions(+), 143 deletions(-)
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0001-vi-mem_block-piece_table-part-2.patch
Type: text/x-patch
Size: 20519 bytes
Desc: not available
URL: <http://lists.landley.net/pipermail/toybox-landley.net/attachments/20200119/f6f20311/attachment-0001.bin>


More information about the Toybox mailing list