[Freeipa-devel] [PATCH] 213 use the csv module for ldapupdate

Rob Crittenden rcritten at redhat.com
Tue May 19 13:48:40 UTC 2009


Jason Gerard DeRose wrote:
> On Wed, 2009-05-13 at 17:08 -0400, Rob Crittenden wrote:
>> In ldapupdate I wanted to make things easy on update writers and them 
>> pass in a comma-separated string to make a multi-valued attribute, like:
>>
>> add:objectclass: top, person, inetorgperson
>>
>> This is my last attempt at working around this "feature" before simply 
>> dropping it. It has turned out to be almost more trouble than it is worth.
>>
>> In any case, this patch drops my hackish lex-based parser for the python 
>> csv module. This works a bit nicer anyway. You do have to be a bit 
>> careful about mixing ' and " though.
>>
>> What I've done is set the quote string to whatever the first character 
>> of a line is, defaulting to ". In other words, if you want the quote 
>> character to be ', then pass it as the first character in the update line.
>>
>> Something like:
>>
>> add:name:'"Here is a quoted value, and another", "and one more"'
>>
>> This breaks down to 2 values to be added:
>>
>> "Here is a quoted value, and another"
>> "and one more"
>>
>> rob
> 
> ack.
> 

pushed to master
-------------- next part --------------
A non-text attachment was scrubbed...
Name: smime.p7s
Type: application/x-pkcs7-signature
Size: 3245 bytes
Desc: S/MIME Cryptographic Signature
URL: <http://listman.redhat.com/archives/freeipa-devel/attachments/20090519/3d52f16c/attachment.bin>


More information about the Freeipa-devel mailing list