How can I prevent PerlTidy from aligning assignments but keep adding single spaces?

后端 未结 2 454
广开言路
广开言路 2021-01-05 08:56

How can I prevent PerlTidy from aligning assignments but keep adding single spaces?

This question is similar to How can I prevent PerlTidy from aligning my assignmen

2条回答
  •  广开言路
    2021-01-05 09:53

    The following patch worked for me:

    --- Tidy.pm.org 2009-06-16 22:00:50.000000000 +0200
    +++ Tidy.pm 2010-12-28 09:43:19.625000000 +0100
    @@ -12404,7 +12404,7 @@
             # accept vertical alignment.
    
             # nothing to do if we aren't allowed to change whitespace
    -        if ( !$rOpts_add_whitespace ) {
    +        if ( 1 || !$rOpts_add_whitespace ) {
                 for my $i ( 0 .. $max_index_to_go ) {
                     $matching_token_to_go[$i] = '';
                 }
    

提交回复
热议问题