Stephen McDonald  committed 3c3c869

Fixed removed project_template setup in mezzanine-project. Closes #167.

  • Participants
  • Parent commits b6833b4

Comments (0)

Files changed (1)

File mezzanine/bin/

 #!/usr/bin/env python
 from __future__ import with_statement
+from distutils.dir_util import copy_tree
 from optparse import OptionParser
 import os
+from shutil import move
 from uuid import uuid4
+from mezzanine.utils.importing import path_for_import
 def create_project():
         except ImportError:
             parser.error("Could not import package '%s'" % package_name)
+    # Build the project up copying over the project_template from
+    # each of the packages. An alternate package will overwrite
+    # files from Mezzanine.
+    for package_name in packages:
+        package_path = path_for_import(package_name)
+        copy_tree(os.path.join(package_path, "project_template"), project_path)
+        move(os.path.join(project_path, ""),
+             os.path.join(project_path, ""))
     # Generate a unique SECREY_KEY for the project's setttings module.
     settings_path = os.path.join(os.getcwd(), project_name, "")
     with open(settings_path, "r") as f: