X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=blobdiff_plain;f=author%2Fgenerate-mouse-tiny.pl;h=0484cdba735fc6b230e5e614c532e89032c6e1db;hb=44945c483b194f2d55a9bbcbed628703329f0f42;hp=265cd16078ac11ca10e3540bcb92786c01ef076c;hpb=26cf84ad4e073bf14437108b224e3710a797579a;p=gitmo%2FMouse.git diff --git a/author/generate-mouse-tiny.pl b/author/generate-mouse-tiny.pl index 265cd16..0484cdb 100755 --- a/author/generate-mouse-tiny.pl +++ b/author/generate-mouse-tiny.pl @@ -4,8 +4,10 @@ use warnings; use File::Find; use File::Slurp 'slurp'; use List::MoreUtils 'uniq'; +use autodie; -unlink 'lib/Mouse/Tiny.pm'; +unlink 'lib/Mouse/Tiny.pm' + if -e 'lib/Mouse/Tiny.pm'; my @files; @@ -14,6 +16,7 @@ find({ push @files, $_ if -f $_ && !/Squirrel/ + && !/TypeRegistory/ && !/\bouse/ && !/\.sw[po]$/ }, @@ -41,7 +44,7 @@ print { $handle } << 'EOF'; # if regular Mouse is loaded, bail out unless ($INC{'Mouse.pm'}) { -eval q{ +eval <<'END_OF_TINY'; # tell Perl we already have all of the Mouse files loaded: EOF @@ -55,7 +58,7 @@ print { $handle } "\n# and now their contents\n\n"; print { $handle } $mouse_tiny; -print { $handle } "}; #eval\n} #unless\n\n"; +print { $handle } "END_OF_TINY\n} #unless\n\n"; print { $handle } << 'EOF'; package Mouse::Tiny;