Dist::Zilla::Plugin::Munge::Whitespace - Strip superfluous spaces from pesky files.
version 0.001001
This plugin can be used with Dist::Zilla to remove remove white-space from selected files.
In its default mode of operation, it will strip trailing white-space from the selected files in the following forms:
0x20: The literal space character
0x20
0x9: The literal tab character, otherwise known as \t
0x9
\t
0xD: The Carriage Return character, otherwise known as \r ( But only immediately before a \n )
0xD
\r
[Munge::Whitespace] filename = LICENSE ; *Cough*: https://github.com/Perl-Toolchain-Gang/Software-License/pull/30 filename = Changes match = lib/*.pm ; Power User Options ; Note: turning both of these options on at present would be idiotic. ; unless you like applying substituion regex to whole files just to duplicate a string preserve_trailing = 1 ; Don't nom trailing \s and \t preserve_cr = 1 ; Don't turn \r\n into \n
Note: This is just a standard munger, and will munge any files it gets told to munge.
It will not however write files out anywhere or make your source tree all pretty.
It will however scrub the files you have on their way out to your dist, or on their way out to any other plugins you might have, like CopyFromRelease or CopyFromBuild, and a smart player can probably combine parts of this with either of those and have their dist automatically cleaned up for them when they run dzil build.
CopyFromRelease
CopyFromBuild
dzil build
They might also enjoy the luxurious benefits of having sensitive white-space accidentally sent to a magical wonderland, which breaks their code, or have a glorious race condition where something important they were working on and hadn't gotten committed to git yet get eaten due to the file on disk getting updated, and their editor dutifully rejoicing and prompting to reload their file, which may make them respond to the pavlovian conditioning to click "OK", followed by much wailing and gnashing of teeth.
Please enjoy our quality product, from the team at FootGuns Inc.
finder support.
finder
I figured I could, but YKW,FI.
YKW,FI
tests
Would be useful. But dogfood for now.
indentation normalization
Sounds like work.
Kent Fredric <kentnl@cpan.org>
This software is copyright (c) 2017 by Kent Fredric <kentfredric@gmail.com>.
This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself.
To install Dist::Zilla::Plugin::Munge::Whitespace, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Dist::Zilla::Plugin::Munge::Whitespace
CPAN shell
perl -MCPAN -e shell install Dist::Zilla::Plugin::Munge::Whitespace
For more information on module installation, please visit the detailed CPAN module installation guide.