ppisar pushed to perl-Parse-ErrorString-Perl (master). "Correct patch name"

notifications at fedoraproject.org notifications at fedoraproject.org
Wed Jun 17 14:40:12 UTC 2015


From 07d2ff7e9ed29e7403e1f47631e34645defc2b40 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Petr=20P=C3=ADsa=C5=99?= <ppisar at redhat.com>
Date: Wed, 17 Jun 2015 14:32:11 +0200
Subject: Correct patch name


diff --git a/ErrorString-Perl-0.21-Adjust-to-perl-5.22.patch b/ErrorString-Perl-0.21-Adjust-to-perl-5.22.patch
deleted file mode 100644
index 4360006..0000000
--- a/ErrorString-Perl-0.21-Adjust-to-perl-5.22.patch
+++ /dev/null
@@ -1,100 +0,0 @@
-From ecbaef9c24c50279ad0d9f96927f623998aa8555 Mon Sep 17 00:00:00 2001
-From: =?UTF-8?q?Petr=20P=C3=ADsa=C5=99?= <ppisar at redhat.com>
-Date: Wed, 17 Jun 2015 14:09:37 +0200
-Subject: [PATCH] Adjust to perl-5.22
-MIME-Version: 1.0
-Content-Type: text/plain; charset=UTF-8
-Content-Transfer-Encoding: 8bit
-
-Perl 5.22 changed diagnostic message about undeclard variable with
-this ond other commits:
-
-commit 68567d271d7bcc0392c9f9bdd834ad94db1e4773
-Author: Father Chrysostomos <sprout at cpan.org>
-Date:   Thu Sep 18 22:10:14 2014 -0700
-
-    Update perldiag to reflect ‘Global symbol’ change
-
-    Why didn’t t/porting/diag.t catch this?
-
-This patch adujsts the test input and expected output to match perl 5.22
-wording.
-
-It's also fixes a bug when perldiag POD spanned the message to more
-lines which broke translation into regular expressions. The new-line
-character crept there.
-
-<https://github.com/PadreIDE/Parse-ErrorString-Perl/issues/1>
-
-Signed-off-by: Petr Písař <ppisar at redhat.com>
----
- lib/Parse/ErrorString/Perl.pm |  1 +
- t/04-perldiag.t               | 29 +++++++++++++++++++++++++++--
- 2 files changed, 28 insertions(+), 2 deletions(-)
-
-diff --git a/lib/Parse/ErrorString/Perl.pm b/lib/Parse/ErrorString/Perl.pm
-index f259bf7..8fb6eb1 100644
---- a/lib/Parse/ErrorString/Perl.pm
-+++ b/lib/Parse/ErrorString/Perl.pm
-@@ -93,6 +93,7 @@ sub _prepare_diagnostics {
- 	my %errors;
- 	foreach my $item ( $pom->head1->[1]->over->[0]->item ) {
- 		my $header = $item->title;
-+		$header =~ s/\n/ /g;
- 
- 		my $content = $item->content;
- 		$content =~ s/\s*$//;
-diff --git a/t/04-perldiag.t b/t/04-perldiag.t
-index 3d6ed57..c5017b9 100644
---- a/t/04-perldiag.t
-+++ b/t/04-perldiag.t
-@@ -13,11 +13,36 @@ use Test::Differences;
- #
- # $hell;
- 
--my $msg_compile = <<'ENDofMSG';
-+my $msg_compile;
-+
-+if ( $] < 5.021004 ) {
-+
-+	$msg_compile = <<'ENDofMSG';
- Global symbol "$kaboom" requires explicit package name at error.pl line 8.
- Execution of error.pl aborted due to compilation errors.
- ENDofMSG
- 
-+} else {
-+
-+	$msg_compile = <<'ENDofMSG';
-+Global symbol "$kaboom" requires explicit package name (did you forget to declare "my $kaboom"?) at error.pl line 8.
-+Execution of error.pl aborted due to compilation errors.
-+ENDofMSG
-+
-+}
-+
-+my $message;
-+
-+if ( $] < 5.021004 ) {
-+
-+	$message = q{Global symbol "$kaboom" requires explicit package name};
-+
-+} else {
-+
-+	$message = q{Global symbol "$kaboom" requires explicit package name (did you forget to declare "my $kaboom"?)};
-+
-+}
-+
- my $diagnostics;
- 
- if ( $] < 5.008009 ) {
-@@ -56,7 +81,7 @@ $diagnostics =~ s/\s\n/\n/gs;
- 
- my $parser         = Parse::ErrorString::Perl->new;
- my @errors_compile = $parser->parse_string($msg_compile);
--is( $errors_compile[0]->message, 'Global symbol "$kaboom" requires explicit package name', 'message' );
-+is( $errors_compile[0]->message, $message, 'message' );
- 
- #ok($errors_compile[0]->diagnostics eq $diagnostics, 'diagnostics');
- my $obtained_diagnostics = $errors_compile[0]->diagnostics;
--- 
-2.1.0
-
diff --git a/Parse-ErrorString-Perl-0.21-Adjust-to-perl-5.22.patch b/Parse-ErrorString-Perl-0.21-Adjust-to-perl-5.22.patch
new file mode 100644
index 0000000..4360006
--- /dev/null
+++ b/Parse-ErrorString-Perl-0.21-Adjust-to-perl-5.22.patch
@@ -0,0 +1,100 @@
+From ecbaef9c24c50279ad0d9f96927f623998aa8555 Mon Sep 17 00:00:00 2001
+From: =?UTF-8?q?Petr=20P=C3=ADsa=C5=99?= <ppisar at redhat.com>
+Date: Wed, 17 Jun 2015 14:09:37 +0200
+Subject: [PATCH] Adjust to perl-5.22
+MIME-Version: 1.0
+Content-Type: text/plain; charset=UTF-8
+Content-Transfer-Encoding: 8bit
+
+Perl 5.22 changed diagnostic message about undeclard variable with
+this ond other commits:
+
+commit 68567d271d7bcc0392c9f9bdd834ad94db1e4773
+Author: Father Chrysostomos <sprout at cpan.org>
+Date:   Thu Sep 18 22:10:14 2014 -0700
+
+    Update perldiag to reflect ‘Global symbol’ change
+
+    Why didn’t t/porting/diag.t catch this?
+
+This patch adujsts the test input and expected output to match perl 5.22
+wording.
+
+It's also fixes a bug when perldiag POD spanned the message to more
+lines which broke translation into regular expressions. The new-line
+character crept there.
+
+<https://github.com/PadreIDE/Parse-ErrorString-Perl/issues/1>
+
+Signed-off-by: Petr Písař <ppisar at redhat.com>
+---
+ lib/Parse/ErrorString/Perl.pm |  1 +
+ t/04-perldiag.t               | 29 +++++++++++++++++++++++++++--
+ 2 files changed, 28 insertions(+), 2 deletions(-)
+
+diff --git a/lib/Parse/ErrorString/Perl.pm b/lib/Parse/ErrorString/Perl.pm
+index f259bf7..8fb6eb1 100644
+--- a/lib/Parse/ErrorString/Perl.pm
++++ b/lib/Parse/ErrorString/Perl.pm
+@@ -93,6 +93,7 @@ sub _prepare_diagnostics {
+ 	my %errors;
+ 	foreach my $item ( $pom->head1->[1]->over->[0]->item ) {
+ 		my $header = $item->title;
++		$header =~ s/\n/ /g;
+ 
+ 		my $content = $item->content;
+ 		$content =~ s/\s*$//;
+diff --git a/t/04-perldiag.t b/t/04-perldiag.t
+index 3d6ed57..c5017b9 100644
+--- a/t/04-perldiag.t
++++ b/t/04-perldiag.t
+@@ -13,11 +13,36 @@ use Test::Differences;
+ #
+ # $hell;
+ 
+-my $msg_compile = <<'ENDofMSG';
++my $msg_compile;
++
++if ( $] < 5.021004 ) {
++
++	$msg_compile = <<'ENDofMSG';
+ Global symbol "$kaboom" requires explicit package name at error.pl line 8.
+ Execution of error.pl aborted due to compilation errors.
+ ENDofMSG
+ 
++} else {
++
++	$msg_compile = <<'ENDofMSG';
++Global symbol "$kaboom" requires explicit package name (did you forget to declare "my $kaboom"?) at error.pl line 8.
++Execution of error.pl aborted due to compilation errors.
++ENDofMSG
++
++}
++
++my $message;
++
++if ( $] < 5.021004 ) {
++
++	$message = q{Global symbol "$kaboom" requires explicit package name};
++
++} else {
++
++	$message = q{Global symbol "$kaboom" requires explicit package name (did you forget to declare "my $kaboom"?)};
++
++}
++
+ my $diagnostics;
+ 
+ if ( $] < 5.008009 ) {
+@@ -56,7 +81,7 @@ $diagnostics =~ s/\s\n/\n/gs;
+ 
+ my $parser         = Parse::ErrorString::Perl->new;
+ my @errors_compile = $parser->parse_string($msg_compile);
+-is( $errors_compile[0]->message, 'Global symbol "$kaboom" requires explicit package name', 'message' );
++is( $errors_compile[0]->message, $message, 'message' );
+ 
+ #ok($errors_compile[0]->diagnostics eq $diagnostics, 'diagnostics');
+ my $obtained_diagnostics = $errors_compile[0]->diagnostics;
+-- 
+2.1.0
+
diff --git a/perl-Parse-ErrorString-Perl.spec b/perl-Parse-ErrorString-Perl.spec
index e67f990..7bb2e6c 100644
--- a/perl-Parse-ErrorString-Perl.spec
+++ b/perl-Parse-ErrorString-Perl.spec
@@ -8,7 +8,7 @@ URL:            http://search.cpan.org/dist/Parse-ErrorString-Perl/
 Source0:        http://search.cpan.org/CPAN/authors/id/S/SZ/SZABGAB/Parse-ErrorString-Perl-%{version}.tar.gz
 # Adjust tests to perl-5.22 message format and fix new-line handling,
 # bug #1231254, <https://github.com/PadreIDE/Parse-ErrorString-Perl/issues/1>
-Patch0:         ErrorString-Perl-0.21-Adjust-to-perl-5.22.patch
+Patch0:         Parse-ErrorString-Perl-0.21-Adjust-to-perl-5.22.patch
 BuildArch:      noarch
 BuildRequires:  coreutils
 BuildRequires:  findutils
-- 
cgit v0.10.2


	http://pkgs.fedoraproject.org/cgit/perl-Parse-ErrorString-Perl.git/commit/?h=master&id=07d2ff7e9ed29e7403e1f47631e34645defc2b40


More information about the perl-devel mailing list