I would expect the same output of the following two commands, but the first one looks wrong to me:
% echo abc^ABC.123 | sed 's/[^A-z0-9]/_/g'
% echo abc^ABC.123 | sed 's/[^[:alnum:]]/_/g'
abc_ABC_123By the way, gsed does the same. Am I missing something?..
I hope I am putting this in the area.
I am running FreeBSD 10.3 x86_64 ZFS with fully encrypted HDD.
I want to put a CR-LF after every uppercase Q followed by a number, i.e. Q4, Q75, Q453,
In vim, I have tried:
As well as several variations.
Al of a sudden sed began to act differently on FreeBSD 11
On FreeBSD 11.0 following script (<------> - tab character)
# cat file
sed -E -i '.orig' \
<------>-e '/^SEARCHED_LINE/ a\