Delete block of text that matches first line
sed -i '/Some arbitrary text to match/,/^$/d' filename
Append hyphens using sed
echo "your 1st line\nyour 2nd line" >> file
Remove grouped new lines and consolidate them to one new line
sed '/^$/N;/^\n$/D' inputfile
Recursively replace matching string
grep -rli 'old-word' * | xargs -i@ sed -i 's/old-word/new-word/g' @
Insert line after specific line
sed -i '<line number> a <what you want to write>' filename
Insert line after matching line (or before)
sed -e '/regex_match/a\' -e 'replacement_text' file
sed -e '/regex_match/i\' -e 'replacement_text' file