install script: corrected the install script.

Thu, 05 Apr 2018 19:39:21 +0200

author
Detlev Offenbach <detlev@die-offenbachs.de>
date
Thu, 05 Apr 2018 19:39:21 +0200
changeset 6216
2a0eeba143e7
parent 6215
4f4581b7a02a
child 6217
35b9e03ffcd6

install script: corrected the install script.

eric6.desktop file | annotate | diff | comparison | revisions
install.py file | annotate | diff | comparison | revisions
--- a/eric6.desktop	Wed Apr 04 19:49:10 2018 +0200
+++ b/eric6.desktop	Thu Apr 05 19:39:21 2018 +0200
@@ -1,7 +1,7 @@
 [Desktop Entry]
 Version=1.0
 Type=Application
-Exec=eric6@MARKER@
+Exec=@BINDIR@/eric6@MARKER@
 MimeType=text/x-python;
 Icon=eric@MARKER@
 Terminal=false
--- a/install.py	Wed Apr 04 19:49:10 2018 +0200
+++ b/install.py	Thu Apr 05 19:39:21 2018 +0200
@@ -302,6 +302,8 @@
     @param dst destination file name (string)
     @param marker marker to be used (string)
     """
+    global cfg
+    
     if sys.version_info[0] == 2:
         f = codecs.open(src, "r", "utf-8")
     else:
@@ -309,6 +311,7 @@
     text = f.read()
     f.close()
     
+    text = text.replace("@BINDIR@", cfg['bindir'])
     text = text.replace("@MARKER@", marker)
     if marker:
         t_marker = " ({0})".format(PythonTextMarkers[marker])
@@ -963,7 +966,8 @@
                 marker)
         elif os.getuid() >= 1000:
             # it is assumed, that user ids start at 1000
-            localPath = os.path.join(os.path.expanduser("~"), ".local")
+            localPath = os.path.join(os.path.expanduser("~"),
+                                     ".local", "share")
             # create directories first
             for directory in [os.path.join(localPath, name)
                               for name in ("pixmaps", "applications",

eric ide

mercurial