RefactoringRope/RefactoringClient.py

branch
server_client_variant
changeset 167
3c8e875d0326
parent 166
6fc202183b3b
child 168
53d76b4fc1ac
--- a/RefactoringRope/RefactoringClient.py	Sat Sep 16 16:40:50 2017 +0200
+++ b/RefactoringRope/RefactoringClient.py	Sat Sep 16 18:51:19 2017 +0200
@@ -14,11 +14,11 @@
 
 sys.path.insert(0, os.path.dirname(__file__))
 if sys.version_info[0] >= 3:
-    path = os.path.join(os.path.dirname(__file__), 'rope_py3')
+    rope_path = os.path.join(os.path.dirname(__file__), 'rope_py3')
 else:
-    path = os.path.join(os.path.dirname(__file__), 'rope_py2')
+    rope_path = os.path.join(os.path.dirname(__file__), 'rope_py2')
     str = unicode   # __IGNORE_WARNING__
-sys.path.insert(0, path)
+sys.path.insert(0, rope_path)
 
 import rope
 import rope.base.project
@@ -134,14 +134,12 @@
         result = {
             "RopeFolderName": self.__project.ropefolder.real_path,
             "DefaultConfig": self.__project._default_config(),
+            "RopeHelpFile": os.path.join(
+                rope_path, "rope", "docs", "overview.txt"),
+            "RopeInfo": rope.INFO,
+            "RopeVersion": rope.VERSION,
+            "RopeCopyright": rope.COPYRIGHT,
         }
-        if sys.version_info[0] >= 3:
-            directory = 'rope_py3'
-        else:
-            directory = 'rope_py2'
-        result["RopeHelpFile"] = os.path.join(
-            os.path.dirname(__file__), directory,
-            "rope", "docs", "overview.txt")
         
         self.sendJson("Config", result)
     

eric ide

mercurial