install local urls
This commit is contained in:
parent
781e2b06ec
commit
df4410517a
1 changed files with 7 additions and 0 deletions
|
|
@ -105,6 +105,13 @@ if os.path.exists('__init__.py'):
|
||||||
new_apps = apps.strip() + ',\n"%s"\n' % name
|
new_apps = apps.strip() + ',\n"%s"\n' % name
|
||||||
local_settings = local_settings.replace(apps, new_apps)
|
local_settings = local_settings.replace(apps, new_apps)
|
||||||
local_settings_changed = True
|
local_settings_changed = True
|
||||||
|
if 'LOCAL_URLPATTERNS' not in local_settings:
|
||||||
|
local_settings += '''
|
||||||
|
LOCAL_URLPATTERNS = [
|
||||||
|
[r'^(?P<id>[A-Z0-9].*)/source(?P<position>[\d\.]+)\.(?P<format>.*)$', 'p_for_power.views.source_frame'],
|
||||||
|
]
|
||||||
|
'''
|
||||||
|
local_settings_changed = True
|
||||||
if local_settings_changed:
|
if local_settings_changed:
|
||||||
with open(local_settings_py, 'w') as fd:
|
with open(local_settings_py, 'w') as fd:
|
||||||
fd.write(local_settings)
|
fd.write(local_settings)
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue