m-chrzan.xyz
aboutsummaryrefslogtreecommitdiff
path: root/sed.md
blob: 3122058c7e505934bf33caaa60ba647a988dc01d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
# Sed, the standard stream editor

Typical substitution:

    sed -e 's/pattern/replacement/flags'

Can do multiple:

    sed -e 's/pattern/replacement/flags; s/bla/ble/'

Back references require extended regexes:

    sed -r -e 's/"(\w+)"/\1/'