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

Re: svn commit: r18634 - trunk/contrib/client-side

From: Peter Samuelson <peter_at_p12n.org>
Date: 2006-02-28 01:49:45 CET

[blair@tigris.org]
> def is_wc(dir):
> """Check if a directory is a working copy."""
> - if not os.path.isdir(dir):
> - return False
> - if os.path.isdir(os.path.join(dir, ".svn")):
> - return True
> - if os.path.isdir(os.path.join(dir, "_svn")):
> - return True
> - return False
> + return os.path.isdir(os.path.join(dir, ".svn")) or \
> + os.path.isdir(os.path.join(dir, "_svn"))

I *almost* said the same thing, but first I checked to see if other
functions in svnmerge.py worked correctly with a symlink. And they
don't - they run stuff like 'svn info {dir}', which won't work with a
symlink. (Well, not in 1.3.0, at least.)

So I think it was valid to check for os.path.isdir(dir).

Received on Tue Feb 28 01:50:59 2006

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.