13 points · by marttt · 6y ago · 14 comments
Homepage: http://sam.cat-v.org/
Paper by Rob Pike: http://doc.cat-v.org/plan_9/4th_edition/papers/sam/
And another paper by Pike on sam's command language (at the core of which are what he calls 'structural regular expressions'): http://doc.cat-v.org/bell_labs/sam_lang_tutorial/sam_tut.pdf
https://news.ycombinator.com/item?id=4120513
And a cheat sheet linked there:
I use the list command to dump out sections of the program until I find where I want to edit and then add / edit lines whilst I can still see the listing at the top of the screen.
Source: DBA.