Fixed an issue causing wrong project file entries if the project is generated in the root on windows. 6_0_x

Fri, 30 Oct 2015 18:01:42 +0100

author
Detlev Offenbach <detlev@die-offenbachs.de>
date
Fri, 30 Oct 2015 18:01:42 +0100
branch
6_0_x
changeset 4513
b893c71f6f66
parent 4504
01abe0758487
child 4520
2e6fbd9f9fac

Fixed an issue causing wrong project file entries if the project is generated in the root on windows.

Project/Project.py file | annotate | diff | comparison | revisions
--- a/Project/Project.py	Fri Oct 23 19:44:22 2015 +0200
+++ b/Project/Project.py	Fri Oct 30 18:01:42 2015 +0100
@@ -3211,7 +3211,10 @@
             if self.ppath and path == self.ppath:
                 return ""
             else:
-                return path[len(self.ppath) + 1:]
+                relpath = path[len(self.ppath):]
+                if relpath.startswith(("/", "\\")):
+                    relpath = relpath[1:]
+                return relpath
         else:
             return path
         

eric ide

mercurial