4 ms·
I must inform you that there is a user who uses sed over all other text editors: me. I do use vi but I could easily survive without it; I have countless custom
by ised 13y ago
I must inform you that there is a user who uses sed over all other text editors: me. I do use vi but I could easily survive without it; I have countless custom utilities that rely on sed. Surviving without sed would be difficult. Imagine a system that has pipes but where you cannot "write to disk"; where you do not have a TMPDIR for ed to use. With sed, this poses no problem.
- VikingCoder 13y agoJust out of curiosity - your resume was written in sed?
- ised 13y agoActually, I used fmt. Then groff and ghostscript. The job of fmt could be done with sed, of course. As many of HN'ers know, sed can perform the functions of many other UNIX utils. If used as an "all-purpose" program, perhaps it raises the possibility of the typical mantras about "the right tool for the job". But consider this: editing/transforming text (e.g. output from other programs) as a "job" is somewhat all-encompassing under UNIX. Everything can be a "file" and every file can be represented as "text" (e.g. ASCII, hex). What varies is the context in which you do this job of editing/transforming. It might be preprocessing source code (text) for gcc or maybe it's preprocessing a resume (text) for groff. "When all you know is a sed, everything is a text." - Unknown