|
|
|
Clear questions and runnable code get the best and fastest answer |
|
| PerlMonks |
Re: CPAN's perltidy to the rescue!by davido (Bishop) |
| on Jul 13, 2012 at 19:06 UTC ( #981705=note: print w/ replies, xml ) | Need Help?? |
|
I agree. I think perltidy is great. (That's perltidy for the search-impared). I feel more productive when I keep my code formatted reasonably well as I'm working with it. But before significant commits (especially ones that will get merged back into a more stable branch), I usually pass it through perltidy first (This works out best if everyone plays by the same rules, or else your 'git diff' becomes a log of all the changes perltidy made, and the potential for merge rejects increases). Often when I compare what I thought was reasonable formatting with what perltidy comes up with, I have to agree with its assessment. But there's a consistent issue that always bugged me. It has to do with how it chooses to indent a qw// list (by default). Here's a contrived example:
Finally it annoyed me enough that I dug into the docs and discovered the -ntqw command line switch. Much happier now. :) Dave
In Section
Meditations
|
|
||||||||||||||||||||||