[Python-3000-checkins] r64263 - in python/branches/py3k: Tools/scripts/svneol.py

martin.v.loewis python-3000-checkins at python.org
Sat Jun 14 03:51:58 CEST 2008


Author: martin.v.loewis
Date: Sat Jun 14 03:51:58 2008
New Revision: 64263

Log:
Merged revisions 64262 via svnmerge from 
svn+ssh://pythondev@svn.python.org/python/trunk

........
  r64262 | martin.v.loewis | 2008-06-14 03:50:46 +0200 (Sa, 14 Jun 2008) | 2 lines
  
  Support subversion repositories of version 8.
........


Modified:
   python/branches/py3k/   (props changed)
   python/branches/py3k/Tools/scripts/svneol.py

Modified: python/branches/py3k/Tools/scripts/svneol.py
==============================================================================
--- python/branches/py3k/Tools/scripts/svneol.py	(original)
+++ python/branches/py3k/Tools/scripts/svneol.py	Sat Jun 14 03:51:58 2008
@@ -33,9 +33,21 @@
 import re
 import os
 
+def propfile(root, fn):
+    default = os.path.join(root, ".svn", "props", fn+".svn-work")
+    try:
+        format = int(open(os.path.join(root, ".svn", "format")).read().strip())
+    except IOError:
+        return default
+    # XXX I don't know what version uses what format;
+    # this condition is just anecdotal
+    if format >= 8:
+        return os.path.join(root, ".svn", "prop-base", fn+".svn-base")
+    return default
+
 def proplist(root, fn):
     "Return a list of property names for file fn in directory root"
-    path = os.path.join(root, ".svn", "props", fn+".svn-work")
+    path = propfile(root, fn)
     try:
         f = open(path)
     except IOError:


More information about the Python-3000-checkins mailing list