Replacing capitals with normal letters using SED

Needed to change CAPITAL variable names to normal in a long SQL-syntax file. Sourceforge had a way to do it with SED.

GSED 4.+ supports the \L& and \U& switches to transform everything to lowercase or uppercase respectively:

sed 's/MyRegExp/\L&/g'

changes the regular expression MyRegExp into lowercase.


Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s