Como substituir um texto e excluir outro texto usando sed

$ sed -e "s/foo/bar/" -e "/FOO/d"
Upvote answer :-)