
Where grep came from [video] - signa11
https://www.youtube.com/watch?v=NTfOnGZUZDk
======
amorousf00p
Kernighan is so nice to listen to compared to some of the the hot air balloons
in software today. I use awk everywhere (and have for many years) and am
deeply indebted to BK and AR for their work on and custody of that language.

~~~
fjarlq
AR = Arnold Robbins, [http://www.skeeve.com/](http://www.skeeve.com/)

------
ahurmazda
I hope these videos will live on for many years to come. Absolutely amazing
and rich oral history of many things we take for granted in our daily lives.

~~~
curiousgal
>many things we take for granted in our daily lives.

The entitlement we live in nowadays vis à vis technology continues to blow my
mind, from some condescending attitudes towards free software that forms the
building block of a myriad of products to the "disappointment" some consumers
express when a new released chip isn't twice as fast as the old iteration.
There's a lot going on behind the scene and even by saying so I am
underestimating just how much our civilisation has put in effort into the
things that we use on a daily basis and pay to attention to.

~~~
User23
This is why I get mad when people piss on RMS. No need to dwell on his
defects, he has served our community immeasurably.

~~~
krapp
If you're talking about people making fun of his weight or appearance or other
strange behaviors, then I agree.

But RMS didn't descend from Mount Sinai with the Four Freedoms carved into
stone by the finger of God or anything. He's just a man with an opinion, and
his ideas are not above criticism regardless of what he's done for the
community.

~~~
mattl
No. But he did live in a community of sharing that was destroyed by
proprietary software and he has spent 45 years developing free software. So
many should pay his ideas more respect than they do because they like to make
it about his person life.

~~~
User23
Wholeheartedly agree!

This entire thing we have going wouldn't be possible without the GNU project.
And GNU would never have happened without RMS. The man is a giant. A giant
with huge glaring flaws, but every single one of us that did anything with
unix-like OSes in the past 30 years owes the man.

Sadly I fear that much like Peirce, Stallman will be forgotten by history
because of the acumen of his primary detractors.

~~~
ezequiel-garzon
Wouldn’t the BSDs have happened sooner or later without GNU, and without
Linus? I’m grateful for the contributions of both men (who by the way have
expressed quite different ideological stances), but I still think it’s an
interesting question.

Edit: grammar.

~~~
mattl
Maybe yes. But BSD was encumbered by the AT&T nonsense for approximately a
third of the free software community’s history. That’s a long time to sit
around and do nothing.

------
type0
Great remark at the end: "they had one great disadvantage: none of them were
Ken Thompson"

Aside from retrocomputing is there any actual use for ed in this day and age
though? [https://sanctum.geek.nz/arabesque/actually-using-
ed/](https://sanctum.geek.nz/arabesque/actually-using-ed/)

~~~
FfejL
In a sense, yes. 'sed' is basically 'ed' for streams. Not exactly the same
syntax & commands, but very very close.

------
eltoozero
Wait, that’s Brian Kernighan?

The K in K&R C Programming???

Mind blown, what an excellent dude!

~~~
jedimastert
He actually has a lot of really awesome oral history/lecture videos on that
same channel. He's an incredible "casual oral history" storyteller.

------
dorfsmay
If ed looked familiar is because you use a derivative of it in vim, in ex-
mode. You can also run ex standalone, which is great to automate file changes.

[https://en.wikipedia.org/wiki/Ex_(text_editor)](https://en.wikipedia.org/wiki/Ex_\(text_editor\))

~~~
wglb
It looks familiar to me because I wrote a tutorial for it for Coherent and
used it for many years before David Conroy wrote MicroEmacs.

vim, not so much.

~~~
sverige
Well, if you went down the emacs path in 1985 when MicroEmacs was released
(near as I can tell anyway), that was six years before vim was released, so I
think you meant to say "vi," not "vim."

Some of us still use plain old vi and not vim, which is why I'm a little
touchy about it, I guess. (I mean, what do you need with all those damn
plugins, anyway? Might as well use emacs in that case.)

~~~
dorfsmay
I moved from vi and vi clones to vim for its Unicode support, but then started
learning all its more advanced operations and have been enjoying them since
then.

------
monkeywork
I wonder how his students did at the assignment he mentioned at the end :)

~~~
sverhagen
I can only imagine the learning opportunities just from comparing their
results with the real grep. The original being built on an 8-bit 32kb RAM
nothing little environment is not something many people are naturally inclined
to optimize for anymore. And for people to even implement any kind of non-
trivial spec, in this case presented as another working application, I imagine
every result was different, and incompatible.

~~~
greenyoda
> _The original being built on an 8-bit 32kb RAM_

Actually, the PDP/11 was a 16-bit machine.

------
hnarayanan
Such an excellent story teller!

~~~
topicseed
I love his videos on Computerphile! Incredible source of hardcore computing
knowledge.

------
Bromskloss
The small step from ed to regular expressions seems like a giant leap in
sophistication to me.

~~~
MetaDark
Well Ken Thompson didn't actually invent the idea of regular expressions, but
he was probably one of the first people to implement them in software. Regular
languages and expressions were first formalized in 1951 by Stephen Kleene and
I assume Ken Thompson used this research to implement them.

------
bch
I was most excited to learn that ed(1) is pronounced “eee dee”.

~~~
superflyguy
... by literally four people.

~~~
cat199
... who literally created it.

~~~
andremat
... please repeat after me: gif.

~~~
mattl
I generally go with “GIF with a soft G is the format, GIF with a hard G is the
culture.”

~~~
kevin_thibedeau
Everyone involved in the creation of GIF and CompuShow pronounce it as "jif".
Anything else is sacrelige.

~~~
ts4z
CompuServe.

~~~
kevin_thibedeau
CompuShow was the DOS GIF viewer.

~~~
ts4z
D’oh. Thanks.

------
lprd
I had no idea grep was made over night! Thoroughly enjoyed the video and
subbed to the YouTube channel. Thanks for sharing!

~~~
dws
Extracted from working code overnight, which in those days on that equipment
was still quite an accomplishment.

------
usermac
[https://youtu.be/NTfOnGZUZDk?t=505](https://youtu.be/NTfOnGZUZDk?t=505) to
jump to it and did you notice... is he wearing a Casio watch from that same
time period?

------
bariswheel
I went down the rabbit hole hard on this YouTube channel, great content.

------
smadge
Kernighan saved the most interesting fact for his last comment: both grep and
ed were written in assembly, not C!

~~~
jedimastert
I actually didn't know that either! I wonder if grep & ed actually predate
C...It's also very possible that K&R might have thought about C as a toy or
novelty at the time.

------
cartercole
I named my whole company after grep: grepwords.com and I had never knew
this... cool history to learn

------
textmode
tl;dr The idea for grep, like sed, began in the mind of Lee McMahon. The
program grep was implemented by Thompson. I recall reading that the program
sed was first implemented by Ritchie, and later McMahon himself. Is this
correct?

------
webbrahmin
I watched this video today and here it is on Hacker News. What a coincidence.

