[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

Re: [PATCH] cvs2svn on windows (resend)

From: Russell Yanofsky <rey4_at_columbia.edu>
Date: 2003-07-26 01:21:38 CEST

Francois Beausoleil wrote:
> Ok, I applied Russel's patch. I get an error:
> ...
> File "E:\svn-trunk\tools\cvs2svn\cvs2svn.py", line 325, in
> relative_name
> assert fname[:l] == cvsroot and fname[l] == os.sep
> NameError: global name 'l' is not defined

I don't see how you can get this error unless there is something wrong with your
patch program or you applied the patch to the wrong version of cvs2svn.py. The
relevant section of the patch reads:

@@ -323,11 +323,8 @@

 def relative_name(cvsroot, fname):
   l = len(cvsroot)
- if fname[:l] == cvsroot:
- if fname[l] == '/':
- return fname[l+1:]
- return fname[l:]
- return l
+ assert fname[:l] == cvsroot and fname[l] == os.sep
+ return string.replace(fname[l+1:], os.sep, '/')

So the variable l will always be defined.

- Russ

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Sat Jul 26 01:24:18 2003

This is an archived mail posted to the Subversion Dev mailing list.

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.