r55294 - in /trunk/libgravatar-url-perl: ./ debian/ debian/source/ lib/Gravatar/ lib/Unicornify/ t/

ansgar-guest at users.alioth.debian.org ansgar-guest at users.alioth.debian.org
Fri Apr 2 13:46:30 UTC 2010


Author: ansgar-guest
Date: Fri Apr  2 13:46:20 2010
New Revision: 55294

URL: http://svn.debian.org/wsvn/pkg-perl/?sc=1&rev=55294
Log:
* New upstream release.
* Use minimal debian/rules.
* Use source format 3.0 (quilt).
* debian/copyright: Minor changes for current DEP-5 proposal.
* debian/control: Move build-dep on perl (>= 5.10) | libmodule-build-perl to
  Build-Depends-Indep.
* Bump Standards-Version to 3.8.4.
* Add myself to Uploaders.

Added:
    trunk/libgravatar-url-perl/MANIFEST.SKIP
      - copied unchanged from r55293, branches/upstream/libgravatar-url-perl/current/MANIFEST.SKIP
    trunk/libgravatar-url-perl/debian/source/
    trunk/libgravatar-url-perl/debian/source/format
    trunk/libgravatar-url-perl/lib/Unicornify/
      - copied from r55293, branches/upstream/libgravatar-url-perl/current/lib/Unicornify/
    trunk/libgravatar-url-perl/t/unicornify.t
      - copied unchanged from r55293, branches/upstream/libgravatar-url-perl/current/t/unicornify.t
Modified:
    trunk/libgravatar-url-perl/Build.PL
    trunk/libgravatar-url-perl/Changes
    trunk/libgravatar-url-perl/MANIFEST
    trunk/libgravatar-url-perl/META.yml
    trunk/libgravatar-url-perl/SIGNATURE
    trunk/libgravatar-url-perl/debian/changelog
    trunk/libgravatar-url-perl/debian/control
    trunk/libgravatar-url-perl/debian/copyright
    trunk/libgravatar-url-perl/debian/rules
    trunk/libgravatar-url-perl/lib/Gravatar/URL.pm
    trunk/libgravatar-url-perl/t/deprecated.t
    trunk/libgravatar-url-perl/t/url.t

Modified: trunk/libgravatar-url-perl/Build.PL
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libgravatar-url-perl/Build.PL?rev=55294&op=diff
==============================================================================
--- trunk/libgravatar-url-perl/Build.PL (original)
+++ trunk/libgravatar-url-perl/Build.PL Fri Apr  2 13:46:20 2010
@@ -34,6 +34,7 @@
         'Digest::MD5'       => 0,
         'Carp'              => 0,
         perl                => '5.6.0',
+        'parent'            => 0,
     },
 );
 

Modified: trunk/libgravatar-url-perl/Changes
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libgravatar-url-perl/Changes?rev=55294&op=diff
==============================================================================
--- trunk/libgravatar-url-perl/Changes (original)
+++ trunk/libgravatar-url-perl/Changes Fri Apr  2 13:46:20 2010
@@ -1,3 +1,15 @@
+1.02  Thu Apr  1 15:36:52 PDT 2010
+    New Features
+    * Added Unicornify::URL for generated unicorn avatars, OMG!!!
+      http://unicornify.appspot.com/whats-this
+
+    Incompatible Changes
+    * short_keys is now the default, as per Gravatar protocol documentation
+
+    Protocol Updates
+    * Document that Gravatar has a new default option, 404.
+
+
 1.01  Thu Apr  9 13:11:32 PDT 2009
     Protocol Updates
     (The Gravatar protocol changed, so we're changing with it)

Modified: trunk/libgravatar-url-perl/MANIFEST
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libgravatar-url-perl/MANIFEST?rev=55294&op=diff
==============================================================================
--- trunk/libgravatar-url-perl/MANIFEST (original)
+++ trunk/libgravatar-url-perl/MANIFEST Fri Apr  2 13:46:20 2010
@@ -1,10 +1,13 @@
 Build.PL
 Changes
 lib/Gravatar/URL.pm
+lib/Unicornify/URL.pm
 MANIFEST
+MANIFEST.SKIP
 META.yml
 t/deprecated.t
 t/error.t
 t/id.t
+t/unicornify.t
 t/url.t
 SIGNATURE    Added here by Module::Build

Modified: trunk/libgravatar-url-perl/META.yml
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libgravatar-url-perl/META.yml?rev=55294&op=diff
==============================================================================
--- trunk/libgravatar-url-perl/META.yml (original)
+++ trunk/libgravatar-url-perl/META.yml Fri Apr  2 13:46:20 2010
@@ -1,30 +1,34 @@
 ---
+abstract: 'Make URLs for Gravatars from an email address'
+author: []
+build_requires:
+  Test::More: 0.4
+  Test::Warn: 0.11
+configure_requires:
+  Module::Build: 0.2808
+generated_by: 'Module::Build version 0.3603'
+keywords:
+  - Gravatar
+license: perl
+meta-spec:
+  url: http://module-build.sourceforge.net/META-spec-v1.4.html
+  version: 1.4
 name: Gravatar-URL
-version: 1.01
-author: []
-abstract: Make URLs for Gravatars from an email address
-license: perl
+provides:
+  Gravatar::URL:
+    file: lib/Gravatar/URL.pm
+    version: 1.02
+  Unicornify::URL:
+    file: lib/Unicornify/URL.pm
+    version: 1.02
+requires:
+  Carp: 0
+  Digest::MD5: 0
+  URI::Escape: 0
+  parent: 0
+  perl: v5.6.0
 resources:
   bugtracker: http://rt.cpan.org/Public/Dist/Display.html?Name=Gravatar-URL
   license: http://dev.perl.org/licenses/
   repository: http://github.com/schwern/gravatar-url/tree/master
-requires:
-  Carp: 0
-  Digest::MD5: 0
-  URI::Escape: 0
-  perl: 5.6.0
-build_requires:
-  Test::More: 0.4
-  Test::Warn: 0.11
-provides:
-  Gravatar::URL:
-    file: lib/Gravatar/URL.pm
-    version: 1.01
-generated_by: Module::Build version 0.32
-meta-spec:
-  url: http://module-build.sourceforge.net/META-spec-v1.2.html
-  version: 1.2
-keywords:
-  - Gravatar
-configure_requires:
-  Module::Build: 0.2808
+version: 1.02

Modified: trunk/libgravatar-url-perl/SIGNATURE
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libgravatar-url-perl/SIGNATURE?rev=55294&op=diff
==============================================================================
--- trunk/libgravatar-url-perl/SIGNATURE (original)
+++ trunk/libgravatar-url-perl/SIGNATURE Fri Apr  2 13:46:20 2010
@@ -1,5 +1,5 @@
 This file contains message digests of all files listed in MANIFEST,
-signed via the Module::Signature module, version 0.55.
+signed via the Module::Signature module, version 0.61.
 
 To verify the content in this distribution, first make sure you have
 Module::Signature installed, then type:
@@ -14,19 +14,22 @@
 -----BEGIN PGP SIGNED MESSAGE-----
 Hash: SHA1
 
-SHA1 da6f215441f5f4c2ef0f1ac5347aad253ff6c50f Build.PL
-SHA1 b3682d5f2e0318d0d3d23aac866f997c8ed37410 Changes
-SHA1 7758b0be320c022c1ce8ca12ac464354d371b1d3 MANIFEST
-SHA1 4299310ce303d6be6ffc9ab65ed04728f744e3ec META.yml
-SHA1 15653f61d2fa90771833e0c8b6a24dd45863c588 lib/Gravatar/URL.pm
-SHA1 218d731c6d9ccf14c33a3b3db3faff3f4c6a24b4 t/deprecated.t
+SHA1 57fcac9d7b6888138ff4dc8774afb60a7ccf1dd1 Build.PL
+SHA1 76ff0820d7e50e966cbaf111221c75fb0ce88e0a Changes
+SHA1 5e4f8a6316dceb7d6bc6c5b3c49ad6941a5ea6f4 MANIFEST
+SHA1 8e76a4d7da7ca9b32f67f3675bbd42d34a25cd37 MANIFEST.SKIP
+SHA1 26e8d176f1b88898994d4325f713f4e4675af21a META.yml
+SHA1 2588ede38e5ddd7060bcafae1086ed3ca134fab5 lib/Gravatar/URL.pm
+SHA1 19711694d10060b613ca024cd37dc5e45a8f4e15 lib/Unicornify/URL.pm
+SHA1 02f21c26f52380259046ea05ae9d560b8a5c5072 t/deprecated.t
 SHA1 0250d25f32bcfe6dafab0b3892f4575959ef6890 t/error.t
 SHA1 3b4f3259bb95a336b73ecd2c06bf96dd30637a0a t/id.t
-SHA1 a1daffcb9416394c540b324b21a022b2b61c8a3d t/url.t
+SHA1 7bdb7b0b2b440eaade3bb2a968c4919c7c2d4666 t/unicornify.t
+SHA1 b027b15e0b5c1257a59bc63ecb8b7c3336119c8f t/url.t
 -----BEGIN PGP SIGNATURE-----
-Version: GnuPG v1.4.9 (Darwin)
+Version: GnuPG v2.0.13 (Darwin)
 
-iEYEARECAAYFAkneV5QACgkQWMohlhD1QydtfQCfcze4m56PfxlfLG+oTJQIZDXO
-pGIAnjb1uA8ETnr/EWGXnUWGanXjOOC/
-=9cBO
+iEYEARECAAYFAku1IKYACgkQWMohlhD1QyeB0wCgmpW3M4lZElbrcEbqQMMigm3u
+/ukAoMUYiK2LdlG3TaJZxhzBh1fuOp8C
+=WBcp
 -----END PGP SIGNATURE-----

Modified: trunk/libgravatar-url-perl/debian/changelog
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libgravatar-url-perl/debian/changelog?rev=55294&op=diff
==============================================================================
--- trunk/libgravatar-url-perl/debian/changelog (original)
+++ trunk/libgravatar-url-perl/debian/changelog Fri Apr  2 13:46:20 2010
@@ -1,4 +1,4 @@
-libgravatar-url-perl (1.01-2) UNRELEASED; urgency=low
+libgravatar-url-perl (1.02-1) UNRELEASED; urgency=low
 
   [ Nathan Handler ]
   * debian/watch: Update to ignore development releases.
@@ -15,7 +15,17 @@
   * debian/control: Changed: (build-)depend on perl instead of perl-
     modules.
 
- -- Ryan Niebur <ryan at debian.org>  Fri, 25 Sep 2009 00:24:58 -0700
+  [ Ansgar Burchardt ]
+  * New upstream release.
+  * Use minimal debian/rules.
+  * Use source format 3.0 (quilt).
+  * debian/copyright: Minor changes for current DEP-5 proposal.
+  * debian/control: Move build-dep on perl (>= 5.10) | libmodule-build-perl to
+    Build-Depends-Indep.
+  * Bump Standards-Version to 3.8.4.
+  * Add myself to Uploaders.
+
+ -- Ansgar Burchardt <ansgar at 43-1.org>  Fri, 02 Apr 2010 22:17:25 +0900
 
 libgravatar-url-perl (1.01-1) unstable; urgency=low
 

Modified: trunk/libgravatar-url-perl/debian/control
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libgravatar-url-perl/debian/control?rev=55294&op=diff
==============================================================================
--- trunk/libgravatar-url-perl/debian/control (original)
+++ trunk/libgravatar-url-perl/debian/control Fri Apr  2 13:46:20 2010
@@ -1,12 +1,12 @@
 Source: libgravatar-url-perl
 Section: perl
 Priority: optional
-Build-Depends: debhelper (>= 7), perl (>= 5.10) | libmodule-build-perl
-Build-Depends-Indep: libtest-warn-perl (>= 0.11), liburi-perl,
-  perl
+Build-Depends: debhelper (>= 7)
+Build-Depends-Indep: libtest-warn-perl (>= 0.11), liburi-perl, perl,
+ perl (>= 5.10) | libmodule-build-perl (>= 0.2808)
 Maintainer: Debian Perl Group <pkg-perl-maintainers at lists.alioth.debian.org>
-Uploaders: Ryan Niebur <ryan at debian.org>
-Standards-Version: 3.8.1
+Uploaders: Ryan Niebur <ryan at debian.org>, Ansgar Burchardt <ansgar at 43-1.org>
+Standards-Version: 3.8.4
 Homepage: http://search.cpan.org/dist/Gravatar-URL/
 Vcs-Svn: svn://svn.debian.org/pkg-perl/trunk/libgravatar-url-perl/
 Vcs-Browser: http://svn.debian.org/viewsvn/pkg-perl/trunk/libgravatar-url-perl/

Modified: trunk/libgravatar-url-perl/debian/copyright
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libgravatar-url-perl/debian/copyright?rev=55294&op=diff
==============================================================================
--- trunk/libgravatar-url-perl/debian/copyright (original)
+++ trunk/libgravatar-url-perl/debian/copyright Fri Apr  2 13:46:20 2010
@@ -1,17 +1,14 @@
-Format-Specification:
-    http://wiki.debian.org/Proposals/CopyrightFormat?action=recall&rev=196
-Upstream-Maintainer: Michael G Schwern <schwern at pobox.com>
-Upstream-Source: http://search.cpan.org/dist/Gravatar-URL/
-Upstream-Name: Gravatar-URL
+Format-Specification: http://svn.debian.org/wsvn/dep/web/deps/dep5.mdwn?op=file&rev=135
+Maintainer: Michael G Schwern <schwern at pobox.com>
+Source: http://search.cpan.org/dist/Gravatar-URL/
+Name: Gravatar-URL
 
-Files: *
-Copyright: 2007 - 2009, Michael G Schwern <schwern at pobox.com>
-License-Alias: Perl
-License: Artistic | GPL-1+
+Copyright: 2007-2009, Michael G Schwern <schwern at pobox.com>
+License: Artistic or GPL-1+
 
 Files: debian/*
 Copyright: 2009, Ryan Niebur <ryan at debian.org>
-License: Artistic | GPL-1+
+License: Artistic or GPL-1+
 
 License: Artistic
     This program is free software; you can redistribute it and/or modify

Modified: trunk/libgravatar-url-perl/debian/rules
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libgravatar-url-perl/debian/rules?rev=55294&op=diff
==============================================================================
--- trunk/libgravatar-url-perl/debian/rules (original)
+++ trunk/libgravatar-url-perl/debian/rules Fri Apr  2 13:46:20 2010
@@ -1,23 +1,3 @@
 #!/usr/bin/make -f
-
-build: build-stamp
-build-stamp:
-	dh build
-	touch $@
-
-clean:
+%:
 	dh $@
-
-install: install-stamp
-install-stamp: build-stamp
-	dh install
-	touch $@
-
-binary-arch:
-
-binary-indep: install
-	dh $@
-
-binary: binary-arch binary-indep
-
-.PHONY: binary binary-arch binary-indep install clean build

Added: trunk/libgravatar-url-perl/debian/source/format
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libgravatar-url-perl/debian/source/format?rev=55294&op=file
==============================================================================
--- trunk/libgravatar-url-perl/debian/source/format (added)
+++ trunk/libgravatar-url-perl/debian/source/format Fri Apr  2 13:46:20 2010
@@ -1,0 +1,1 @@
+3.0 (quilt)

Modified: trunk/libgravatar-url-perl/lib/Gravatar/URL.pm
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libgravatar-url-perl/lib/Gravatar/URL.pm?rev=55294&op=diff
==============================================================================
--- trunk/libgravatar-url-perl/lib/Gravatar/URL.pm (original)
+++ trunk/libgravatar-url-perl/lib/Gravatar/URL.pm Fri Apr  2 13:46:20 2010
@@ -7,9 +7,9 @@
 use Digest::MD5 qw(md5_hex);
 use Carp;
 
-our $VERSION = '1.01';
-
-use base 'Exporter';
+our $VERSION = '1.02';
+
+use parent 'Exporter';
 our @EXPORT = qw(
     gravatar_id
     gravatar_url
@@ -80,14 +80,15 @@
 
 The url to use if the user has no gravatar or has none that fits your rating requirements.
 
-    default => "http://upload.wikimedia.org/wikipedia/en/8/89/Alfred.jpg"
+    default => "https://secure.wikimedia.org/wikipedia/en/wiki/File:Mad30.jpg"
 
 Relative URLs will be relative to the base (ie. gravatar.com), not your web site.
 
 Gravatar defines special values that you may use as a default to
 produce dynamic default images. These are "identicon", "monsterid" and
-"wavatar".  See L<http://en.gravatar.com/site/implement/url> for more
-info.
+"wavatar".  "404" will cause the URL to return an HTTP 404 "Not Found"
+error instead.  See L<http://en.gravatar.com/site/implement/url> for
+more info.
 
 If omitted, Gravatar will serve up their default image, the blue G.
 
@@ -113,9 +114,14 @@
 If true, use short key names when constructing the URL.  "s" instead
 of "size", "r" instead of "ratings" and so on.
 
-short_keys defaults to false, but may default to true in the future.
+short_keys defaults to true.
 
 =cut
+
+my %defaults = (
+    short_keys  => 1,
+    base        => $Gravatar_Base
+);
 
 sub gravatar_url {
     my %args = @_;
@@ -126,7 +132,7 @@
     exists $args{id} xor exists $args{email} or
         croak "Both an id and an email were given.  gravatar_url() only takes one";
 
-    my $base = $args{base} || $Gravatar_Base;
+    _apply_defaults(\%args, \%defaults);
 
     if ( exists $args{size} ) {
         $args{size} >= 1 and $args{size} <= 512
@@ -150,6 +156,7 @@
     $args{default} = uri_escape($args{default})
         if $args{default};
 
+    # Use a fixed order to make testing easier
     my @pairs;
     for my $arg ( qw( rating size default border ) ) {
         next unless exists $args{$arg};
@@ -159,7 +166,7 @@
         push @pairs, join("=", $key, $args{$arg});
     }
 
-    my $uri = $base;
+    my $uri = $args{base};
     $uri   .= "/" unless $uri =~ m{/$};
     $uri   .= $args{gravatar_id};
     $uri   .= "?".join("&", at pairs) if @pairs;
@@ -167,6 +174,17 @@
     return $uri;
 }
 
+
+sub _apply_defaults {
+    my($hash, $defaults) = @_;
+
+    for my $key (keys %$defaults) {
+        next if exists $hash->{$key};
+        $hash->{$key} = $defaults->{$key};
+    }
+
+    return;
+}
 
 =head3 B<gravatar_id>
 

Modified: trunk/libgravatar-url-perl/t/deprecated.t
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libgravatar-url-perl/t/deprecated.t?rev=55294&op=diff
==============================================================================
--- trunk/libgravatar-url-perl/t/deprecated.t (original)
+++ trunk/libgravatar-url-perl/t/deprecated.t Fri Apr  2 13:46:20 2010
@@ -17,5 +17,5 @@
         id   => '12345',
         base => 'http://www.example.com/gravatar',
         border => "FFF"
-    ), "http://www.example.com/gravatar/12345?border=FFF";
+    ), "http://www.example.com/gravatar/12345?b=FFF";
 } {carped => "The border key is deprecated"};

Modified: trunk/libgravatar-url-perl/t/url.t
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libgravatar-url-perl/t/url.t?rev=55294&op=diff
==============================================================================
--- trunk/libgravatar-url-perl/t/url.t (original)
+++ trunk/libgravatar-url-perl/t/url.t Fri Apr  2 13:46:20 2010
@@ -34,14 +34,14 @@
         [{ default => "/local.png",
            email   => $email
          },
-         "$base/$id?default=%2Flocal.png",
+         "$base/$id?d=%2Flocal.png",
         ],
         
         [{ default => "/local.png",
            rating  => 'X',
            email   => $email,
          },
-         "$base/$id?rating=x&default=%2Flocal.png",
+         "$base/$id?r=x&d=%2Flocal.png",
         ],
         
         [{ default  => "/local.png",
@@ -49,7 +49,7 @@
            rating   => 'R',
            size     => 80
          },
-         "$base/$id?rating=r&size=80&default=%2Flocal.png"
+         "$base/$id?r=r&s=80&d=%2Flocal.png"
         ],
 
         [{ default => "/local.png",
@@ -57,7 +57,7 @@
            size    => 45,
            email   => $email,
          },
-         "$base/$id?rating=pg&size=45&default=%2Flocal.png"
+         "$base/$id?r=pg&s=45&d=%2Flocal.png"
         ],
 
         [{ default => "/local.png",
@@ -65,7 +65,7 @@
            size    => 45,
            email   => $email,
          },
-         "$base/$id?rating=pg&size=45&default=%2Flocal.png"
+         "$base/$id?r=pg&s=45&d=%2Flocal.png"
         ],
 
         [{ default => "/local.png",
@@ -76,6 +76,14 @@
          },
          "$base/$id?r=pg&s=45&d=%2Flocal.png"
         ],
+        [{ default => "/local.png",
+           rating  => 'PG',
+           size    => 45,
+           email   => $email,
+           short_keys => 0,
+         },
+         "$base/$id?rating=pg&size=45&default=%2Flocal.png"
+        ],
     );
 
     # Add tests for the special defaults.
@@ -83,13 +91,13 @@
         my $test = [{ default => $special,
                       email   => $email,
                     },
-                    "$base/$id?default=$special",
+                    "$base/$id?d=$special",
                    ];
         push @tests, $test;
     }
 
     for my $test (@tests) {
-        my($args, $url ) = @$test;
+        my($args, $url) = @$test;
         is gravatar_url( %$args ), $url, join ", ", keys %$args;
     }
 }




More information about the Pkg-perl-cvs-commits mailing list