Fixed the Subversion and PySvn status commands (issue caused by latest Subversion and PySvn updates).

Mon, 09 Apr 2012 18:51:29 +0200

author
Detlev Offenbach <detlev@die-offenbachs.de>
date
Mon, 09 Apr 2012 18:51:29 +0200
changeset 1773
05265254f212
parent 1772
f325dfdc8f6b
child 1775
cbe864be5274
child 1778
31e70a6f8e7f

Fixed the Subversion and PySvn status commands (issue caused by latest Subversion and PySvn updates).

Plugins/VcsPlugins/vcsPySvn/SvnStatusDialog.py file | annotate | diff | comparison | revisions
Plugins/VcsPlugins/vcsPySvn/SvnStatusMonitorThread.py file | annotate | diff | comparison | revisions
Plugins/VcsPlugins/vcsSubversion/SvnStatusDialog.py file | annotate | diff | comparison | revisions
Plugins/VcsPlugins/vcsSubversion/SvnStatusMonitorThread.py file | annotate | diff | comparison | revisions
--- a/Plugins/VcsPlugins/vcsPySvn/SvnStatusDialog.py	Mon Apr 09 17:02:31 2012 +0200
+++ b/Plugins/VcsPlugins/vcsPySvn/SvnStatusDialog.py	Mon Apr 09 18:51:29 2012 +0200
@@ -324,10 +324,10 @@
                     uptodate = True
                     if file.repos_text_status != pysvn.wc_status_kind.none:
                         uptodate = uptodate and \
-                            file.repos_text_status == file.text_status
+                            file.repos_text_status != pysvn.wc_status_kind.modified
                     if file.repos_prop_status != pysvn.wc_status_kind.none:
                         uptodate = uptodate and \
-                            file.repos_prop_status == file.prop_status
+                            file.repos_prop_status != pysvn.wc_status_kind.modified
                     
                     lockState = " "
                     if file.entry is not None and \
--- a/Plugins/VcsPlugins/vcsPySvn/SvnStatusMonitorThread.py	Mon Apr 09 17:02:31 2012 +0200
+++ b/Plugins/VcsPlugins/vcsPySvn/SvnStatusMonitorThread.py	Mon Apr 09 18:51:29 2012 +0200
@@ -73,9 +73,11 @@
             for file in allFiles:
                 uptodate = True
                 if file.repos_text_status != pysvn.wc_status_kind.none:
-                    uptodate = uptodate and file.repos_text_status == file.text_status
+                    uptodate = uptodate and \
+                        file.repos_text_status != pysvn.wc_status_kind.modified
                 if file.repos_prop_status != pysvn.wc_status_kind.none:
-                    uptodate = uptodate and file.repos_prop_status == file.prop_status
+                    uptodate = uptodate and \
+                        file.repos_prop_status != pysvn.wc_status_kind.modified
                 
                 status = ""
                 if not uptodate:
--- a/Plugins/VcsPlugins/vcsSubversion/SvnStatusDialog.py	Mon Apr 09 17:02:31 2012 +0200
+++ b/Plugins/VcsPlugins/vcsSubversion/SvnStatusDialog.py	Mon Apr 09 18:51:29 2012 +0200
@@ -189,11 +189,11 @@
         }
         
         self.rx_status = \
-            QRegExp('(.{8})\\s+([0-9-]+)\\s+([0-9?]+)\\s+([\\w?]+)\\s+(.+)\\s*')
-            # flags (8 anything), revision, changed rev, author, path
+            QRegExp('(.{8,9})\\s+([0-9-]+)\\s+([0-9?]+)\\s+([\\w?]+)\\s+(.+)\\s*')
+            # flags (8 or 9 anything), revision, changed rev, author, path
         self.rx_status2 = \
-            QRegExp('(.{8})\\s+(.+)\\s*')
-            # flags (8 anything), path
+            QRegExp('(.{8,9})\\s+(.+)\\s*')
+            # flags (8 or 9 anything), path
         self.rx_changelist = \
             QRegExp('--- \\S+ .([\\w\\s]+).:\\s+')
             # three dashes, Changelist (translated), quote,
@@ -492,14 +492,14 @@
                     path = self.rx_status.cap(5).strip()
                     
                     self.__generateItem(flags[0], flags[1], flags[2], flags[3],
-                                        flags[4], flags[5], flags[7], rev,
+                                        flags[4], flags[5], flags[-1], rev,
                                         change, author, path)
                 elif self.rx_status2.exactMatch(s):
                     flags = self.rx_status2.cap(1)
                     path = self.rx_status2.cap(2).strip()
                     
                     self.__generateItem(flags[0], flags[1], flags[2], flags[3],
-                                        flags[4], flags[5], flags[7], "", "",
+                                        flags[4], flags[5], flags[-1], "", "",
                                         "", path)
                 elif self.rx_changelist.exactMatch(s):
                     self.currentChangelist = self.rx_changelist.cap(1)
--- a/Plugins/VcsPlugins/vcsSubversion/SvnStatusMonitorThread.py	Mon Apr 09 17:02:31 2012 +0200
+++ b/Plugins/VcsPlugins/vcsSubversion/SvnStatusMonitorThread.py	Mon Apr 09 18:51:29 2012 +0200
@@ -32,9 +32,9 @@
         self.__ioEncoding = Preferences.getSystem("IOEncoding")
         
         self.rx_status1 = \
-            QRegExp('(.{8})\\s+([0-9-]+)\\s+(.+)\\s*')
+            QRegExp('(.{8,9})\\s+([0-9-]+)\\s+(.+)\\s*')
         self.rx_status2 = \
-            QRegExp('(.{8})\\s+([0-9-]+)\\s+([0-9?]+)\\s+([\\w?]+)\\s+(.+)\\s*')
+            QRegExp('(.{8,9})\\s+([0-9-]+)\\s+([0-9?]+)\\s+([\\w?]+)\\s+(.+)\\s*')
     
     def _performMonitor(self):
         """
@@ -85,8 +85,8 @@
                     else:
                         continue
                     if flags[0] in "ACDMR" or \
-                       (flags[0] == " " and flags[7] == "*"):
-                        if flags[7] == "*":
+                       (flags[0] == " " and flags[-1] == "*"):
+                        if flags[-1] == "*":
                             status = "U"
                         else:
                             status = flags[0]

eric ide

mercurial