hobo: uncompress skeleton site when initializing a new site (#5839)
This commit is contained in:
parent
a405180a9f
commit
7f77ed94b4
|
@ -51,6 +51,12 @@ class CmdCheckHobos(Command):
|
|||
print 'initializing instance in', pub.app_dir
|
||||
os.mkdir(pub.app_dir)
|
||||
pub.initialize_app_dir()
|
||||
|
||||
skeleton_filepath = os.path.join(global_app_dir, 'skeletons',
|
||||
service.get('template_name'))
|
||||
if os.path.exists(skeleton_filepath):
|
||||
pub.import_zip(file(skeleton_filepath))
|
||||
|
||||
else:
|
||||
print 'updating instance in', pub.app_dir
|
||||
pub.set_config()
|
||||
|
@ -63,6 +69,7 @@ class CmdCheckHobos(Command):
|
|||
if not pub.cfg.get('misc'):
|
||||
pub.cfg['misc'] = {}
|
||||
pub.cfg['misc']['sitename'] = service.get('title').encode('utf-8')
|
||||
pub.cfg['misc']['frontoffice-url'] = service.get('base_url').encode('utf-8')
|
||||
pub.write_cfg()
|
||||
|
||||
def configure_authentication_methods(self, service, pub):
|
||||
|
|
Loading…
Reference in New Issue