Sed stands for Stream EDitor. It is one of the basic tools in the POSIX environment - it processes one or more files according to an editing script and writes the results to standard output. Created in Bell Labs, it has been around since mid-70s.

learn more… | top users | synonyms

6
votes
1answer
54 views

Bash script to convert NIST vectors to debug scripts

TL;DR: The Bash script (below) is converting a published, somewhat-structured text file into a format usable by my testing infrastructure. It's slow, I think it's ugly -- although it is fully ...
3
votes
1answer
39 views

Extracting performance statistics from FTP session transcript

I've borrowed and written the following code to output the disconnect time. All works well but I'm curious as to how I could tighten/ shorten the code. If anyone feels like having some fun then I'd ...
4
votes
1answer
1k views

Bash Shell Script uses Sed to create and insert multiple lines after a particular line in an existing file

This code seems to work, but I'd like someone with shell-fu to review it. Is the temp file a good idea? How would I do without? Is sed the right tool? Any other general advice for improving my ...
1
vote
1answer
139 views

Parsing of a file using sed

I have a file containing lines having this structure : ...
2
votes
2answers
167 views

Add getters and setters to a set of variables

Any improvements are welcome. a.bat ...
2
votes
2answers
532 views

Tiny bash script: Is sed necessary here?

I've recently discovered the power of sed; regular expressions seem like they'll take a lifetime to master. This tiny script uses both to add zero before the single digit in file names. Can this be ...
4
votes
1answer
345 views

Transpose a matrix using sed

Transpose the following data from: ...