[svn:parrot] r49029 - trunk/runtime/parrot/library

whiteknight at svn.parrot.org whiteknight at svn.parrot.org
Thu Sep 16 00:33:02 UTC 2010


Author: whiteknight
Date: Thu Sep 16 00:33:01 2010
New Revision: 49029
URL: https://trac.parrot.org/parrot/changeset/49029

Log:
fix to distutils to work with the new parrot smolder server. Adds in an optional smolder_credentials option which can be used to specify the login credentals for the server

Modified:
   trunk/runtime/parrot/library/distutils.pir

Modified: trunk/runtime/parrot/library/distutils.pir
==============================================================================
--- trunk/runtime/parrot/library/distutils.pir	Wed Sep 15 20:03:04 2010	(r49028)
+++ trunk/runtime/parrot/library/distutils.pir	Thu Sep 16 00:33:01 2010	(r49029)
@@ -2061,6 +2061,11 @@
 
 a hash
 
+=item smolder_credentials
+
+A string, of the form "USERNAME:PASSWORD" to be used as the credentials for
+the server. The default is "parrot-autobot:qa_rocks"
+
 =back
 
 =cut
@@ -2155,6 +2160,18 @@
     set $P0, 1
     $P0[0] = archive
     push contents, $P0
+    $S0 = 'parrot-autobot:qa_rocks'
+    $I0 = exists kv['smolder_credentials']
+    unless $I0 goto L5
+    $S0 = kv['smolder_credentials']
+  L5:
+    $P0 = split ':', $S0
+    $P1 = $P0[0]
+    push contents, "username"
+    push contents, $P1
+    $P1 = $P0[1]
+    push contents, "password"
+    push contents, $P1
     load_bytecode 'LWP/UserAgent.pir'
     .local pmc ua, response
     ua = new ['LWP';'UserAgent']


More information about the parrot-commits mailing list