There's a ton of camelCase methods and variables in this template (PHP/Smarty), and through some glitch or blunder on my part I just automagically converted them to all lowercase. What gives? I'm now stuck coverting all of these back to the way they were before by hand
I'll guess that you had a block selected in visual mode, and hit u
. With a visual block selected u
converts the selection to lower-case (U
converts the selection to upper-case).
By vim do you mean the unix program? If so check for the same file with a ~ after it. Emacs and vim both save the previous file.
Press v
and select all the parts that you wish to change case. after that press ~
, this will change the case of all selected characters.
About camleCase, you have no option than to recheck your code again.
You could have done it if you're at the top of the file and do guG
and generally, gu<motion>
will lowercase everything in that motion. Maybe even if you'd just typed gu
and done something with the mouse maybe you got hit?