r36482 - in /branches/upstream/libsocialtext-resting-utils-perl/current: Changes META.yml Makefile.PL lib/Socialtext/Resting/DefaultRester.pm lib/Socialtext/Resting/Utils.pm t/getopt.t t/rester.conf t/wiki-localcopy.t

thialme-guest at users.alioth.debian.org thialme-guest at users.alioth.debian.org
Tue May 26 22:57:33 UTC 2009


Author: thialme-guest
Date: Tue May 26 22:57:29 2009
New Revision: 36482

URL: http://svn.debian.org/wsvn/pkg-perl/?sc=1&rev=36482
Log:
[svn-upgrade] Integrating new upstream version, libsocialtext-resting-utils-perl (0.20)

Modified:
    branches/upstream/libsocialtext-resting-utils-perl/current/Changes
    branches/upstream/libsocialtext-resting-utils-perl/current/META.yml
    branches/upstream/libsocialtext-resting-utils-perl/current/Makefile.PL
    branches/upstream/libsocialtext-resting-utils-perl/current/lib/Socialtext/Resting/DefaultRester.pm
    branches/upstream/libsocialtext-resting-utils-perl/current/lib/Socialtext/Resting/Utils.pm
    branches/upstream/libsocialtext-resting-utils-perl/current/t/getopt.t
    branches/upstream/libsocialtext-resting-utils-perl/current/t/rester.conf
    branches/upstream/libsocialtext-resting-utils-perl/current/t/wiki-localcopy.t

Modified: branches/upstream/libsocialtext-resting-utils-perl/current/Changes
URL: http://svn.debian.org/wsvn/pkg-perl/branches/upstream/libsocialtext-resting-utils-perl/current/Changes?rev=36482&op=diff
==============================================================================
--- branches/upstream/libsocialtext-resting-utils-perl/current/Changes (original)
+++ branches/upstream/libsocialtext-resting-utils-perl/current/Changes Tue May 26 22:57:29 2009
@@ -1,4 +1,7 @@
 Revision history for Socialtext-Utils
+
+0.20 - Sat May 23 23:09:00 PDT 2009
+  - Bugfixes to better work with and without Crypt::CBC
 
 0.19 - Mon Apr 20 11:22:58 PDT 2009
   - s/localtime/gmtime/ when posting pages

Modified: branches/upstream/libsocialtext-resting-utils-perl/current/META.yml
URL: http://svn.debian.org/wsvn/pkg-perl/branches/upstream/libsocialtext-resting-utils-perl/current/META.yml?rev=36482&op=diff
==============================================================================
--- branches/upstream/libsocialtext-resting-utils-perl/current/META.yml (original)
+++ branches/upstream/libsocialtext-resting-utils-perl/current/META.yml Tue May 26 22:57:29 2009
@@ -1,10 +1,11 @@
 # http://module-build.sourceforge.net/META-spec.html
 #XXXXXXX This is a prototype!!!  It will change in the future!!! XXXXX#
 name:         Socialtext-Resting-Utils
-version:      0.19
+version:      0.20
 version_from: lib/Socialtext/Resting/Utils.pm
 installdirs:  site
 requires:
+    Crypt::CBC:                    0
     Getopt::Long:                  2.36
     JSON::XS:                      2.1
     Socialtext::Resting:           0.27

Modified: branches/upstream/libsocialtext-resting-utils-perl/current/Makefile.PL
URL: http://svn.debian.org/wsvn/pkg-perl/branches/upstream/libsocialtext-resting-utils-perl/current/Makefile.PL?rev=36482&op=diff
==============================================================================
--- branches/upstream/libsocialtext-resting-utils-perl/current/Makefile.PL (original)
+++ branches/upstream/libsocialtext-resting-utils-perl/current/Makefile.PL Tue May 26 22:57:29 2009
@@ -15,6 +15,7 @@
         'Getopt::Long'        => '2.36',
         'JSON::XS'            => '2.1',
         'YAML'                => 0,
+        'Crypt::CBC'          => 0,
         },
     EXE_FILES           => [
         'bin/wikedit', 

Modified: branches/upstream/libsocialtext-resting-utils-perl/current/lib/Socialtext/Resting/DefaultRester.pm
URL: http://svn.debian.org/wsvn/pkg-perl/branches/upstream/libsocialtext-resting-utils-perl/current/lib/Socialtext/Resting/DefaultRester.pm?rev=36482&op=diff
==============================================================================
--- branches/upstream/libsocialtext-resting-utils-perl/current/lib/Socialtext/Resting/DefaultRester.pm (original)
+++ branches/upstream/libsocialtext-resting-utils-perl/current/lib/Socialtext/Resting/DefaultRester.pm Tue May 26 22:57:29 2009
@@ -82,7 +82,8 @@
 }
 
 sub _load_config {
-    my $file = shift;
+    my $file       = shift;
+    my $second_try = shift;
 
     unless (-e $file) {
         open(my $fh, ">$file") or die "Can't open $file: $!";
@@ -106,8 +107,10 @@
         }
     }
 
-    if (-w $file and $opts{password} and $opts{password} !~ /^CRYPTED_/) {
-        _change_password($file, $opts{password}) or return _load_config($file);
+    my $pw = $opts{password};
+    if (!$second_try and -w $file and $pw and $pw !~ /^CRYPTED_/) {
+        _change_password($file, $opts{password})
+            or return _load_config($file, 'i already tried once');
     }
 
     if ($opts{password} and $opts{password} =~ m/^CRYPTED_(.+)/) {

Modified: branches/upstream/libsocialtext-resting-utils-perl/current/lib/Socialtext/Resting/Utils.pm
URL: http://svn.debian.org/wsvn/pkg-perl/branches/upstream/libsocialtext-resting-utils-perl/current/lib/Socialtext/Resting/Utils.pm?rev=36482&op=diff
==============================================================================
--- branches/upstream/libsocialtext-resting-utils-perl/current/lib/Socialtext/Resting/Utils.pm (original)
+++ branches/upstream/libsocialtext-resting-utils-perl/current/lib/Socialtext/Resting/Utils.pm Tue May 26 22:57:29 2009
@@ -8,7 +8,7 @@
 
 =cut
 
-our $VERSION = '0.19';
+our $VERSION = '0.20';
 
 =head1 SYNOPSIS
 

Modified: branches/upstream/libsocialtext-resting-utils-perl/current/t/getopt.t
URL: http://svn.debian.org/wsvn/pkg-perl/branches/upstream/libsocialtext-resting-utils-perl/current/t/getopt.t?rev=36482&op=diff
==============================================================================
--- branches/upstream/libsocialtext-resting-utils-perl/current/t/getopt.t (original)
+++ branches/upstream/libsocialtext-resting-utils-perl/current/t/getopt.t Tue May 26 22:57:29 2009
@@ -53,7 +53,11 @@
         open($fh, 't/rester.conf') or die;
         my $contents = <$fh>;
         close $fh;
-        like $contents, qr/password = CRYPTED_\S+/, 'password was crypted';
+        eval 'require Crypt::CBC';
+        SKIP: {
+            skip "no Crypt::CBC", 1 if $@;
+            like $contents, qr/password = CRYPTED_\S+/, 'pw was crypted';
+        }
     }
 }
 

Modified: branches/upstream/libsocialtext-resting-utils-perl/current/t/rester.conf
URL: http://svn.debian.org/wsvn/pkg-perl/branches/upstream/libsocialtext-resting-utils-perl/current/t/rester.conf?rev=36482&op=diff
==============================================================================
--- branches/upstream/libsocialtext-resting-utils-perl/current/t/rester.conf (original)
+++ branches/upstream/libsocialtext-resting-utils-perl/current/t/rester.conf Tue May 26 22:57:29 2009
@@ -1,5 +1,5 @@
 username  = user-name
-password = CRYPTED_53616c7465645f5f05bdca0f948bd38f4fb20f162e7cee1ab58a0a7ddd046269
+password = CRYPTED_53616c7465645f5f2d397bd8c1652e2f91cd5a4e89a6c1a603aabd84b7340aea
 workspace = work-space
 server    = http://socialtext.net
 class     = Socialtext::Resting::Mock

Modified: branches/upstream/libsocialtext-resting-utils-perl/current/t/wiki-localcopy.t
URL: http://svn.debian.org/wsvn/pkg-perl/branches/upstream/libsocialtext-resting-utils-perl/current/t/wiki-localcopy.t?rev=36482&op=diff
==============================================================================
--- branches/upstream/libsocialtext-resting-utils-perl/current/t/wiki-localcopy.t (original)
+++ branches/upstream/libsocialtext-resting-utils-perl/current/t/wiki-localcopy.t Tue May 26 22:57:29 2009
@@ -81,12 +81,15 @@
 
 exit;
 
-sub _make_tempdir {
-    my $dir = "t/localstore.$$";
-    rmtree $dir if -d $dir;
-    mkpath $dir;
-    END { rmtree $dir if $dir and -d $dir }
-    return $dir;
+{
+    my $dir;
+    sub _make_tempdir {
+        $dir = "t/localstore.$$";
+        rmtree $dir if -d $dir;
+        mkpath $dir;
+        END { rmtree $dir if $dir and -d $dir }
+        return $dir;
+    }
 }
 
 sub _setup_rester {




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