<?xml version="1.0" encoding="UTF-8"?>
<commit>
  <added type="array">
    <added>
      <filename>pootle/install_dirs.py</filename>
    </added>
  </added>
  <modified type="array">
    <modified>
      <diff>@@ -30,6 +30,7 @@ from ConfigParser import ConfigParser
 
 # syspath_override is not needed and does not exist when Pootle is installed
 # from a distribution package or via &quot;setup.py install&quot;
+from pootle.install_dirs import *
 try:
     import syspath_override
 except ImportError:</diff>
      <filename>pootle/settings.py</filename>
    </modified>
    <modified>
      <diff>@@ -164,15 +164,15 @@ def list_tree(target_base, root):
 class PootleInstall(DistutilsInstall):
     def run(self):
         DistutilsInstall.run(self)
-        self.update_settingspy()
+        self.update_install_dirs_py()
 
-    def update_settingspy(self):
-        # Get the right target location of localsettings.py, depending on
+    def update_install_dirs_py(self):
+        # Get the right target location of install_dirs.py, depending on
         # whether --root or --prefix was specified
-        settingspy_path = path.abspath(path.join(self.install_lib, 'pootle', 'settings.py'))
+        install_dirs_py_path = path.abspath(path.join(self.install_lib, 'pootle', 'install_dirs.py'))
 
-        if not path.isfile(settingspy_path):
-            raise Exception('settings.py file should exist, but does not. o_O (%s)' % (settingspy_path))
+        if not path.isfile(install_dirs_py_path):
+            raise Exception('install_dirs.py file should exist, but does not. o_O (%s)' % (install_dirs_py_path))
 
         conf_dir = path.abspath(path.join(self.install_data, INSTALL_CONFIG_DIR))
         data_dir = path.abspath(path.join(self.install_data, INSTALL_DATA_DIR))
@@ -188,7 +188,7 @@ class PootleInstall(DistutilsInstall):
             work_dir = util.change_root(self.root, INSTALL_WORKING_DIR)
 
         # Replace directory variables in settings.py to reflect the current installation
-        lines = open(settingspy_path).readlines()
+        lines = open(install_dirs_py_path).readlines()
         config_re = re.compile(r'^CONFIG_DIR\s*=')
         datadir_re = re.compile(r'^DATA_DIR\s*=')
         workdir_re = re.compile(r'^WORKING_DIR\s*=')
@@ -200,7 +200,7 @@ class PootleInstall(DistutilsInstall):
                 lines[i] = &quot;DATA_DIR = '%s'\n&quot; % (data_dir)
             elif workdir_re.match(lines[i]):
                 lines[i] = &quot;WORKING_DIR = '%s'\n&quot; % (work_dir)
-        open(settingspy_path, 'w').write(''.join(lines))
+        open(install_dirs_py_path, 'w').write(''.join(lines))
 
 
 ###############################################################################</diff>
      <filename>setup.py</filename>
    </modified>
  </modified>
  <removed type="array"/>
  <parents type="array">
    <parent>
      <id>192d9289b829bdc70fb83e31c61428fe2bfd3270</id>
    </parent>
  </parents>
  <author>
    <name>alaaosh</name>
    <email>alaaosh@54714841-351b-0410-a198-e36a94b762f5</email>
  </author>
  <url>http://github.com/translateorgza/pootle/commit/c5ff0322bbd84378056bf0eaec7820496576421e</url>
  <id>c5ff0322bbd84378056bf0eaec7820496576421e</id>
  <committed-date>2009-09-02T18:52:41-07:00</committed-date>
  <authored-date>2009-09-02T18:52:41-07:00</authored-date>
  <message>split path variables in seperate files.

this way we isolate the bits modified by setup.py and it makes it easier to split some configs and move them to localsettings.py

git-svn-id: https://translate.svn.sourceforge.net/svnroot/translate/src/trunk/Pootle@12270 54714841-351b-0410-a198-e36a94b762f5</message>
  <tree>f861b14f74629804c7d633949498a24a82ceb4b5</tree>
  <committer>
    <name>alaaosh</name>
    <email>alaaosh@54714841-351b-0410-a198-e36a94b762f5</email>
  </committer>
</commit>
