gnu-sed

GNU implementation of sed, a powerful stream editor for text manipulation

brewmacoslinux
Try with needOr install directly
Source

About

GNU implementation of the famous stream editor

Commands

gsed

Examples

Replace first occurrence of 'old' with 'new' in a file$ gsed -i 's/old/new/' file.txt
Replace all occurrences globally and save backup$ gsed -i.bak 's/pattern/replacement/g' file.txt
Delete lines matching a pattern$ gsed -i '/pattern/d' file.txt