1)
If you have to change one or two letters, use ~ over the letters while in command mode. vi toggles the cases with ~
2) Between a range, say marks a and b
Change to lower case
'b,'a,s/[aA-zZ]/\L&/g
Change to upper case
'b,'a,s/[aA-zZ]/\U&/g
3) Change to upper case thru out the file
%s/[aA-zZ]/\U&/g
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment