List Info

Thread: riedel big problem with pysvn




riedel big problem with pysvn
user name
2006-10-02 17:29:43
Dear all,

i need a post-commit script that made a CO on a REP - but it
dosent work as hook-script! If i take it as normal bash
command it works perfectly - have anybody a idea? 

#!/usr/bin/env python

import pysvn # svn-lib
from os import *
import os.path
from sys import *
from string import *

def get_login( realm, username, may_save ):
    return retcode,'riedel','kunde', true

client = pysvn.Client()
client.callback_get_login = get_login  <<< i think
her is the problem the function don't work!
client.checkout('http://localhost/svn/test/
','/tmp/test')

thanks,
steph
____________________________________________________________
___________
Viren-Scan für Ihren PC! Jetzt für jeden. Sofort, online und
kostenlos.
Gleich testen! h
ttp://www.pc-sicherheit.web.de/freescan/?mc=022222

------------------------------------------------------------
---------
To unsubscribe, e-mail: users-unsubscribepysvn.tigris.org
For additional commands, e-mail: users-helppysvn.tigris.org

riedel big problem with pysvn
user name
2006-10-02 22:05:57
On Oct 2, 2006, at 18:29, Stephan Riedel wrote:

> Dear all,
>
> i need a post-commit script that made a CO on a REP -
but it dosent  
> work as hook-script! If i take it as normal bash
command it works  
> perfectly - have anybody a idea?
>
> #!/usr/bin/env python
>
> import pysvn # svn-lib
> from os import *
> import os.path
> from sys import *
> from string import *
>
> def get_login( realm, username, may_save ):
>     return retcode,'riedel','kunde', true

retcode is not defined so get_login will raise an exception.
try this version

def get_login( realm, username, may_save ):
     return 1,'riedel','kunde', true

Oh and change you password if it really kunde.


>
> client = pysvn.Client()
> client.callback_get_login = get_login  <<< i
think her is the  
> problem the function don't work!
> client.checkout('http://localhost/svn/test/
','/tmp/test')
>

Barry

------------------------------------------------------------
---------
To unsubscribe, e-mail: users-unsubscribepysvn.tigris.org
For additional commands, e-mail: users-helppysvn.tigris.org

[1-2]

about | contact  Other archives ( Real Estate discussion Medical topics )