From: Vincent Pit Date: Thu, 25 Aug 2011 12:48:36 +0000 (+0200) Subject: This is 1.04 X-Git-Tag: v1.04^0 X-Git-Url: http://git.vpit.fr/?a=commitdiff_plain;h=81c26bb06329658a6299f6d86df8cbaa9748f362;p=perl%2Fmodules%2FRegexp-Wildcards.git This is 1.04 --- diff --git a/Changes b/Changes index 456b402..7e57943 100644 --- a/Changes +++ b/Changes @@ -1,5 +1,12 @@ Revision history for Regexp-Wildcards +1.04 2011-08-25 12:50 UTC + + Chg : Minor code cleanups. + + Fix : Use Scalar::Util::blessed() to check objects classes. + Scalar::Util is required. + + Fix : Work around Kwalitee test misfailures. + + Upd : The distribution metadata was updated to modern standards. + 1.03 2009-02-26 15:35 UTC + Add : Translating both 'jokers' and 'sql' at the same time. + Doc : Cleanups. diff --git a/META.json b/META.json index b82c844..88cd2fe 100644 --- a/META.json +++ b/META.json @@ -24,6 +24,7 @@ "requires" : { "Carp" : 0, "ExtUtils::MakeMaker" : 0, + "Scalar::Util" : 0, "Test::More" : 0, "Text::Balanced" : 0 } @@ -36,6 +37,7 @@ "runtime" : { "requires" : { "Carp" : 0, + "Scalar::Util" : 0, "Text::Balanced" : 0, "perl" : "5.006" } @@ -54,5 +56,5 @@ "url" : "http://git.profvince.com/?p=perl%2Fmodules%2FRegexp-Wildcards.git" } }, - "version" : "1.03" + "version" : "1.04" } diff --git a/META.yml b/META.yml index 0aa78b6..0c0ee7a 100644 --- a/META.yml +++ b/META.yml @@ -1,30 +1,34 @@ ---- #YAML:1.0 -name: Regexp-Wildcards -version: 1.03 -abstract: Converts wildcard expressions to Perl regular expressions. +--- +abstract: 'Converts wildcard expressions to Perl regular expressions.' author: - - Vincent Pit -license: perl -distribution_type: module -configure_requires: - ExtUtils::MakeMaker: 0 + - 'Vincent Pit ' build_requires: - ExtUtils::MakeMaker: 0 - Test::More: 0 + Carp: 0 + ExtUtils::MakeMaker: 0 + Scalar::Util: 0 + Test::More: 0 + Text::Balanced: 0 +configure_requires: + ExtUtils::MakeMaker: 0 +dynamic_config: 0 +generated_by: 'ExtUtils::MakeMaker version 6.59, CPAN::Meta::Converter version 2.112150' +license: perl +meta-spec: + url: http://module-build.sourceforge.net/META-spec-v1.4.html + version: 1.4 +name: Regexp-Wildcards +no_index: + directory: + - t + - inc requires: - Carp: 0 - perl: 5.006 - Text::Balanced: 0 + Carp: 0 + Scalar::Util: 0 + Text::Balanced: 0 + perl: 5.006 resources: - bugtracker: http://rt.cpan.org/NoAuth/ReportBug.html?Queue=Regexp-Wildcards - homepage: http://search.cpan.org/dist/Regexp-Wildcards/ - license: http://dev.perl.org/licenses/ - repository: http://git.profvince.com/perl/modules/Regexp-Wildcards.git -no_index: - directory: - - t - - inc -generated_by: ExtUtils::MakeMaker version 6.48 -meta-spec: - url: http://module-build.sourceforge.net/META-spec-v1.4.html - version: 1.4 + bugtracker: http://rt.cpan.org/NoAuth/ReportBug.html?Queue=Regexp-Wildcards + homepage: http://search.cpan.org/dist/Regexp-Wildcards/ + license: http://dev.perl.org/licenses/ + repository: http://git.profvince.com/?p=perl%2Fmodules%2FRegexp-Wildcards.git +version: 1.04 diff --git a/README b/README index 6c12d59..4e5e7aa 100644 --- a/README +++ b/README @@ -3,7 +3,7 @@ NAME expressions. VERSION - Version 1.03 + Version 1.04 SYNOPSIS use Regexp::Wildcards; @@ -17,12 +17,12 @@ SYNOPSIS $re = $rw->convert('%a_c%', 'sql'); # Turn SQL wildcards into regexps. $rw = Regexp::Wildcards->new( - do => [ qw/jokers brackets/ ], # Do jokers and brackets. - capture => [ qw/any greedy/ ], # Capture *'s greedily. + do => [ qw ], # Do jokers and brackets. + capture => [ qw ], # Capture *'s greedily. ); $rw->do(add => 'groups'); # Don't escape groups. - $rw->capture(rem => [ qw/greedy/ ]); # Actually we want non-greedy matches. + $rw->capture(rem => [ qw ]); # Actually we want non-greedy matches. $re = $rw->convert('*a{,(b)?}?c*'); # '(.*?)a(?:|(b).).c(.*?)' $rw->capture(); # No more captures. @@ -124,7 +124,7 @@ METHODS $rw->do(set => 'jokers'); # Only translate jokers. $rw->do('jokers'); # Same. - $rw->do(add => [ qw/sql commas/ ]); # Translate also SQL and commas. + $rw->do(add => [ qw ]); # Translate also SQL and commas. $rw->do(rem => 'jokers'); # Specifying both 'sql' and 'jokers' is useless. $rw->do(); # Translate nothing. @@ -205,7 +205,7 @@ METHODS $rw->capture(set => 'single'); # Only capture "exactly one" metacharacters. $rw->capture('single'); # Same. - $rw->capture(add => [ qw/any greedy/ ]); # Also greedily capture "any" metacharacters. + $rw->capture(add => [ qw ]); # Also greedily capture "any" metacharacters. $rw->capture(rem => 'greedy'); # No more greed please. $rw->capture(); # Capture nothing. @@ -224,7 +224,8 @@ EXPORT An object module shouldn't export any function, and so does this one. DEPENDENCIES - Carp (core module since perl 5), Text::Balanced (since 5.7.3). + Carp (core module since perl 5), Scalar::Util, Text::Balanced (since + 5.7.3). CAVEATS This module does not implement the strange behaviours of Windows shell diff --git a/lib/Regexp/Wildcards.pm b/lib/Regexp/Wildcards.pm index d32c920..59ac6d8 100644 --- a/lib/Regexp/Wildcards.pm +++ b/lib/Regexp/Wildcards.pm @@ -13,13 +13,13 @@ Regexp::Wildcards - Converts wildcard expressions to Perl regular expressions. =head1 VERSION -Version 1.03 +Version 1.04 =cut use vars qw<$VERSION>; BEGIN { - $VERSION = '1.03'; + $VERSION = '1.04'; } =head1 SYNOPSIS