[libsoftware-license-perl] 03/08: removed *short_name patches applied upstream
dod at debian.org
dod at debian.org
Sun Dec 1 17:56:30 UTC 2013
This is an automated email from the git hooks/post-receive script.
dod pushed a commit to branch master
in repository libsoftware-license-perl.
commit c57307bdde571ad502dbbd37d2208ea72774a037
Author: Dominique Dumont <dod at debian.org>
Date: Sun Dec 1 18:35:59 2013 +0100
removed *short_name patches applied upstream
---
debian/patches/new_from_short_name | 70 --------------------------------------
debian/patches/series | 2 --
debian/patches/test-short-name | 23 -------------
3 files changed, 95 deletions(-)
diff --git a/debian/patches/new_from_short_name b/debian/patches/new_from_short_name
deleted file mode 100644
index b9e1bca..0000000
--- a/debian/patches/new_from_short_name
+++ /dev/null
@@ -1,70 +0,0 @@
-Description: Add new_from_short_name method
-Forwarded: no
-Author: Dominique Dumont <dod at debian.org>
-Last-Update: 2013-10-22
-
---- a/lib/Software/LicenseUtils.pm
-+++ b/lib/Software/LicenseUtils.pm
-@@ -1,5 +1,7 @@
- use strict;
- use warnings;
-+use Carp;
-+
- package Software::LicenseUtils;
- {
- $Software::LicenseUtils::VERSION = '0.103006';
-@@ -119,6 +121,36 @@
-
-
-
-+my %short_name = (
-+ 'GPL-1' => [ 'GPL_1' ],
-+ 'GPL-2' => [ 'GPL_2' ],
-+ 'GPL-3' => [ 'GPL_3' ],
-+ 'LGPL-2' => [ 'LGPL_2' ],
-+ 'LGPL-2.1' => [ 'LGPL_2_1' ],
-+ 'LGPL-3' => [ 'LGPL_3_0' ],
-+ 'LGPL-3.0' => [ 'LGPL_3_0' ],
-+ 'Artistic' => [ 'Artistic_1_0' ],
-+ 'Artistic-1' => [ 'Artistic_1_0' ],
-+ 'Artistic-2' => [ 'Artistic_2_0' ],
-+);
-+
-+
-+sub new_from_short_name {
-+ my ( $class, $arg ) = @_;
-+
-+ Carp::croak "no license short name specified"
-+ unless defined $arg->{short_name};
-+ my $short = delete $arg->{short_name};
-+ Carp::croak "Unknow license with short name $short"
-+ unless $short_name{$short};
-+ my @lic_data = @{ $short_name{$short} };
-+
-+ my $lic_file = my $lic_class = 'Software::License::' . shift @lic_data;
-+ $lic_file =~ s!::!/!g;
-+ require "$lic_file.pm";
-+ return $lic_class->new( { %$arg, @lic_data } );
-+}
-+
- 1;
-
- __END__
-@@ -153,6 +185,17 @@
- method makes a guess as to which licenses may apply to the distribution. It
- will return a list of zero or more Software::License instances or classes.
-
-+=head2 new_from_short_name
-+
-+ my $license_object = Software::LicenseUtils->new_from_short_name( {
-+ short_name => 'GPL-1',
-+ holder => 'X. Ample'
-+ }) ;
-+
-+Create a new L<Software::License> object from the license specified
-+with C<short_name>. Known short license names are C<GPL-*>, C<LGPL-*> ,
-+C<Artistic> and C<Artistic-*>
-+
- =head1 AUTHOR
-
- Ricardo Signes <rjbs at cpan.org>
diff --git a/debian/patches/series b/debian/patches/series
index a48e948..b26871f 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -1,5 +1,3 @@
-new_from_short_name
-test-short-name
summary_method
artistic_1.0_summary
apache-2-summary
diff --git a/debian/patches/test-short-name b/debian/patches/test-short-name
deleted file mode 100644
index ab8baf4..0000000
--- a/debian/patches/test-short-name
+++ /dev/null
@@ -1,23 +0,0 @@
-Description: Test short name
---- /dev/null
-+++ b/t/short_name.t
-@@ -0,0 +1,19 @@
-+#!perl
-+use strict;
-+use warnings;
-+
-+use Test::More tests => 6;
-+
-+my $class = 'Software::LicenseUtils';
-+require_ok($class);
-+
-+my $license = $class->new_from_short_name({
-+ short_name => 'GPL-1',
-+ holder => 'X. Ample'
-+});
-+
-+is($license->holder, 'X. Ample', '(c) holder');
-+is($license->year, (localtime)[5]+1900, '(c) year');
-+isa_ok($license,'Software::License::GPL_1',"license class");
-+like($license->name, qr/version 1/i, "license name");
-+like($license->fulltext, qr/general public/i, 'license text');
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-perl/packages/libsoftware-license-perl.git
More information about the Pkg-perl-cvs-commits
mailing list