[pypy-svn] rev 2047 - pypy/trunk/src/pypy/tool

hpk at codespeak.net hpk at codespeak.net
Sat Oct 25 12:05:26 CEST 2003


Author: hpk
Date: Sat Oct 25 12:05:25 2003
New Revision: 2047

Modified:
   pypy/trunk/src/pypy/tool/fixeol
Log:
made it ignore non-versioned resources. 



Modified: pypy/trunk/src/pypy/tool/fixeol
==============================================================================
--- pypy/trunk/src/pypy/tool/fixeol	(original)
+++ pypy/trunk/src/pypy/tool/fixeol	Sat Oct 25 12:05:25 2003
@@ -49,12 +49,16 @@
 def asserttextfile(fname):
     "Assert a file is a text file or issue a warning otherwise."
     # safety check to nail binary files
-    if not binary2text(fname):
-        print >> sys.stderr, "*** warning, looks like a binary file:",
-        print >> sys.stderr, fname
-        return
-    # change end-of-line style of each .py and .txt file to 'native'
-    os.system('svn propset svn:eol-style native %s' % fname)
+    try:
+        if not binary2text(fname):
+            print >> sys.stderr, "*** warning, looks like a binary file:",
+            print >> sys.stderr, fname
+            return
+    except IOError, e:
+        print "skipping %r because of %s" %(fname, e)
+    else:
+        # change end-of-line style of each .py and .txt file to 'native'
+        os.system('svn propset svn:eol-style native %s' % fname)
 
 
 def fixpyfiles(ignored, dirname, fnames):


More information about the Pypy-commit mailing list