Is This Insane?

May 17, 2019

[ I’ve been very busy at work this week, and don’t have time to write a proper exercise. My apologies. ]

I stumbled across Twitter account ed1conf that included this method of collaborating with another user on an ed(1) session:

Have two ed(1) sessions open concurrently and want to easily transfer lines between them?

    $ ed -p"a)" a.txt

in another shell

    $ mkfifo fifo
    $ ed -p"b)" b.txt

then

    a) 15,21 w fifo

then

    b) 13r fifo

Can reuse the same fifo bidirectionally. Finally

    !rm fifo

I’m not sure if that’s brilliant or insane! Actually, I’m not even sure if a whole Twitter account devoted to ed(1) is brilliant or insane.

Perhaps you would like to share with us some other examples of brilliant insanity.

Advertisements

2 Responses to “Is This Insane?”

  1. […] to come up with a real programming exercise so he shared what he described as an insane example of collaboration using ed. Actually, it’s not really “collaboration” but a way of sending some lines in one ed session […]

  2. Daniel said

    “Perhaps you would like to share with us some other examples of brilliant insanity.”

    The first thing I thought of was this blog post from 2007, Webserver in bash.

    http://paulbuchheit.blogspot.com/2007/04/webserver-in-bash.html

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

%d bloggers like this: