Corrected some left overs of a failed installation.

Sat, 18 Mar 2017 11:34:01 +0100

author
Detlev Offenbach <detlev@die-offenbachs.de>
date
Sat, 18 Mar 2017 11:34:01 +0100
changeset 5628
3a1bef0560b1
parent 5627
fcffc4cd5e5c
child 5629
1df33bb9df28

Corrected some left overs of a failed installation.

UI/Info.py file | annotate | diff | comparison | revisions
eric6config.py file | annotate | diff | comparison | revisions
install.py file | annotate | diff | comparison | revisions
--- a/UI/Info.py	Sat Mar 18 11:06:48 2017 +0100
+++ b/UI/Info.py	Sat Mar 18 11:34:01 2017 +0100
@@ -10,8 +10,8 @@
 from __future__ import unicode_literals
 
 Program = 'eric6'
-Version = 'rev_0b335d29dd51 (rev. 0b335d29dd51)'
-VersionOnly = 'rev_0b335d29dd51'
+Version = '@@VERSION@@ (rev. @@REVISION@@)'
+VersionOnly = '@@VERSION@@'
 Copyright = 'Copyright (c) 2002 - 2017 Detlev Offenbach' \
             ' <detlev@die-offenbachs.de>'
 BugAddress = 'eric-bugs@eric-ide.python-projects.org'
--- a/eric6config.py	Sat Mar 18 11:06:48 2017 +0100
+++ b/eric6config.py	Sat Mar 18 11:34:01 2017 +0100
@@ -1,38 +1,50 @@
 # -*- coding: utf-8 -*-
+
+# Copyright (c) 2002 - 2017 Detlev Offenbach <detlev@die-offenbachs.de>
 #
-# This module contains the configuration of the individual eric6 installation
-#
+
+"""
+Module containing the default configuration of the eric6 installation.
+"""
+
+from __future__ import unicode_literals
+
+import sys
+import os
+
+__ericDir = os.path.dirname(sys.argv[0])
 
 _pkg_config = {
-    'ericDir': r'/Users/detlev/py3qt50env/lib/python3.6/site-packages/eric6',
-    'ericPixDir': r'/Users/detlev/py3qt50env/lib/python3.6/site-packages/eric6/pixmaps',
-    'ericIconDir': r'/Users/detlev/py3qt50env/lib/python3.6/site-packages/eric6/icons',
-    'ericDTDDir': r'/Users/detlev/py3qt50env/lib/python3.6/site-packages/eric6/DTDs',
-    'ericCSSDir': r'/Users/detlev/py3qt50env/lib/python3.6/site-packages/eric6/CSSs',
-    'ericStylesDir': r'/Users/detlev/py3qt50env/lib/python3.6/site-packages/eric6/Styles',
-    'ericDocDir': r'/Users/detlev/py3qt50env/lib/python3.6/site-packages/eric6/Documentation',
-    'ericExamplesDir': r'/Users/detlev/py3qt50env/lib/python3.6/site-packages/eric6/Examples',
-    'ericTranslationsDir': r'/Users/detlev/py3qt50env/lib/python3.6/site-packages/eric6/i18n',
-    'ericTemplatesDir': r'/Users/detlev/py3qt50env/lib/python3.6/site-packages/eric6/DesignerTemplates',
-    'ericCodeTemplatesDir': r'/Users/detlev/py3qt50env/lib/python3.6/site-packages/eric6/CodeTemplates',
-    'ericOthersDir': r'/Users/detlev/py3qt50env/lib/python3.6/site-packages/eric6',
-    'bindir': r'/Users/detlev/py3qt50env/bin',
-    'mdir': r'/Users/detlev/py3qt50env/lib/python3.6/site-packages',
-    'apidir': r'/Users/detlev/py3qt50env/lib/python3.6/site-packages/PyQt5/Qt/qsci/api',
-    'apis': ['zope-2.10.7.api', 'zope-2.11.2.api', 'zope-3.3.1.api', 'eric6.api', 'Ruby-1.8.7.api', 'Ruby-1.9.1.api', 'qss.api'],
-    'macAppBundlePath': r'/Applications',
-    'macAppBundleName': r'eric6.app',
+    'ericDir': __ericDir,
+    'ericPixDir': os.path.join(__ericDir, 'pixmaps'),
+    'ericIconDir': os.path.join(__ericDir, 'icons'),
+    'ericDTDDir': os.path.join(__ericDir, 'DTDs'),
+    'ericCSSDir': os.path.join(__ericDir, 'CSSs'),
+    'ericStylesDir': os.path.join(__ericDir, "Styles"),
+    'ericDocDir': os.path.join(__ericDir, 'Documentation'),
+    'ericExamplesDir': os.path.join(__ericDir, 'Examples'),
+    'ericTranslationsDir': os.path.join(__ericDir, 'i18n'),
+    'ericTemplatesDir': os.path.join(__ericDir, 'DesignerTemplates'),
+    'ericCodeTemplatesDir': os.path.join(__ericDir, 'CodeTemplates'),
+    'ericOthersDir': __ericDir,
+    'bindir': __ericDir,
+    'mdir': __ericDir,
 }
 
+
 def getConfig(name):
-    '''
+    """
     Module function to get a configuration value.
 
-    @param name name of the configuration value (string)
-    '''
+    @param name name of the configuration value
+    @type str
+    @return requested config value
+    @exception AttributeError raised to indicate an invalid config entry
+    """
     try:
         return _pkg_config[name]
     except KeyError:
         pass
 
-    raise AttributeError('"{0}" is not a valid configuration value'.format(name))
+    raise AttributeError(
+        '"{0}" is not a valid configuration value'.format(name))
--- a/install.py	Sat Mar 18 11:06:48 2017 +0100
+++ b/install.py	Sat Mar 18 11:34:01 2017 +0100
@@ -1089,15 +1089,19 @@
         """    '''\n"""
         """    Module function to get a configuration value.\n"""
         """\n"""
-        """    @param name name of the configuration value (string)\n"""
+        """    @param name name of the configuration value"""
+        """    @type str\n"""
+        """    @exception AttributeError raised to indicate an invalid"""
+        """ config entry\n"""
         """    '''\n"""
         """    try:\n"""
         """        return _pkg_config[name]\n"""
         """    except KeyError:\n"""
         """        pass\n"""
         """\n"""
-        """    raise AttributeError('"{{0}}" is not a valid configuration"""
-        """ value'.format(name))\n"""
+        """    raise AttributeError(\n"""
+        """        '"{{0}}" is not a valid configuration value'"""
+        """.format(name))\n"""
     ).format(
         cfg['ericDir'], cfg['ericPixDir'], cfg['ericIconDir'],
         cfg['ericDTDDir'], cfg['ericCSSDir'],

eric ide

mercurial