I've got a piece of badly formatted Perl code:
if ($a==1){
&err_report("$a");
while($b!=1){
&err_ok();
}
}
I want to reformat it in Vim. After using the command gg=G, the code is formatted as:
if ($a==1){
&err_report("$a");
while($b!=1){
&err_ok();
}
}
Actually, I want to format it in Vim as below:
if ($a==1){
&err_report("$a");
while($b!=1){
&err_ok();
}
}
What should I do?
- After using vim-perl, the auto-formating still doesn't do what I want.