Apr 23, 2003 #1 Ambatim Programmer Joined Feb 28, 2002 Messages 110 Location IN In vi, how can I change the case(from uppercase to lower or vice-versa), of all characters in particular lines, say from line 10 to line 100 ?? If not possible in vi can I do it outside of vi using any commmand ??? Thanks in advance Mallik
In vi, how can I change the case(from uppercase to lower or vice-versa), of all characters in particular lines, say from line 10 to line 100 ?? If not possible in vi can I do it outside of vi using any commmand ??? Thanks in advance Mallik
Apr 23, 2003 #2 Ygor Programmer Joined Feb 21, 2003 Messages 623 Location GB awk '{if (NR>=10 && NR<=100) print toupper($0); else print $0 }' < file1 > file2 Upvote 0 Downvote
Apr 23, 2003 #3 iribach Technical User Joined Oct 12, 2002 Messages 211 Location CH :2,200!tr "[a-z]" "[A-Z" Upvote 0 Downvote
Apr 23, 2003 #4 vgersh99 Programmer Joined Jul 27, 2000 Messages 2,146 Location US cheating...... btw: :2,200!tr '[a-z] '[A-Z]' vlad +----------------------------+ | #include<disclaimer.h> | +----------------------------+ Upvote 0 Downvote
cheating...... btw: :2,200!tr '[a-z] '[A-Z]' vlad +----------------------------+ | #include<disclaimer.h> | +----------------------------+
Apr 23, 2003 1 #5 CaKiwi Programmer Joined Apr 8, 2001 Messages 1,294 Location US To convert a range to all uppercase or lowercase, use 10,100s/.*/\U&/ or 10,100s/.*/\L&/ CaKiwi "I love mankind, it's people I can't stand" - Linus Van Pelt Upvote 0 Downvote
To convert a range to all uppercase or lowercase, use 10,100s/.*/\U&/ or 10,100s/.*/\L&/ CaKiwi "I love mankind, it's people I can't stand" - Linus Van Pelt