Commit Graph

6 Commits

Author SHA1 Message Date
Virgil Dupras
942d2a952d ed: take filename as an argument
This hard-binds ed to the filesystem (I liked the idea of working
only with blockdevs though...), but this is necessary for the
upcoming `w` command. We need some kind of way to tell the
destination to write to truncate itself.

This only has a meaning in the filesystem, but it's necessary to
let the file know that its registered file size has possibly
shrunk.

I thought of alternatives that would have allowed me to keep ed
blkdev-centered, but they were all too hackish to my own taste.

Hence, this new hard-bind on files.
2019-07-20 19:43:07 -04:00
Virgil Dupras
eefadc3917 ed: add support for 'a' and 'i' 2019-07-14 17:35:21 -04:00
Virgil Dupras
77a23cee84 ed: fix bufDelLines logic
It was mostly wrong.
2019-07-14 16:18:33 -04:00
Virgil Dupras
5669884508 ed: read initial contents in bufInit 2019-07-14 12:19:37 -04:00
Virgil Dupras
8af1cf468c ed: add 'd' cmd 2019-07-14 10:32:28 -04:00
Virgil Dupras
e0f2a71dfc apps/ed: print specified line 2019-07-13 14:01:20 -04:00