Commit Graph

15 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
3b0029335a ed: add README 2019-07-14 11:31:14 -04:00
Virgil Dupras
8af1cf468c ed: add 'd' cmd 2019-07-14 10:32:28 -04:00
Virgil Dupras
50d0dc982c ed: check addr bounds 2019-07-14 09:04:51 -04:00
Virgil Dupras
c811d5330c apps/ed: add support for addr ranges 2019-07-13 22:09:17 -04:00
Virgil Dupras
2d9f74c2af apps/ed: refactoring 2019-07-13 21:08:16 -04:00
Virgil Dupras
8cf68dc7ad apps/ed: handle +[n] and -[n] addresses 2019-07-13 16:30:30 -04:00
Virgil Dupras
951dd2206d apps/ed: add the concept of "current line" 2019-07-13 15:28:44 -04:00
Virgil Dupras
e0f2a71dfc apps/ed: print specified line 2019-07-13 14:01:20 -04:00
Virgil Dupras
6dbbfa837d apps/ed: add (dummy) line number processing
Starting to feel interactive...
2019-07-13 11:53:30 -04:00
Virgil Dupras
3491c26132 apps/ed: start implementing I/O 2019-07-13 11:29:06 -04:00
Virgil Dupras
3d474c9121 apps/ed: first steps 2019-07-13 09:57:37 -04:00