mirror of
https://github.com/django/django.git
synced 2025-07-04 09:49:12 +00:00
fix for startproject requiring settings
git-svn-id: http://code.djangoproject.com/svn/django/branches/i18n@1013 bcc190cf-cafb-0310-a4f2-bffc1f526a37
This commit is contained in:
parent
e8d46cb8f1
commit
de42aef09c
@ -1,12 +1,15 @@
|
|||||||
#!/usr/bin/env python
|
#!/usr/bin/env python
|
||||||
from django.core import management
|
from django.core import management
|
||||||
from django.utils import translation
|
|
||||||
from optparse import OptionParser
|
from optparse import OptionParser
|
||||||
import os, sys
|
import os, sys
|
||||||
|
|
||||||
# switch to english, because django-admin creates database content
|
# switch to english, because django-admin creates database content
|
||||||
# like permissions, and those shouldn't contain any translations
|
# like permissions, and those shouldn't contain any translations
|
||||||
|
try:
|
||||||
|
from django.utils import translation
|
||||||
translation.activate('en-us')
|
translation.activate('en-us')
|
||||||
|
except:
|
||||||
|
pass
|
||||||
|
|
||||||
ACTION_MAPPING = {
|
ACTION_MAPPING = {
|
||||||
'adminindex': management.get_admin_index,
|
'adminindex': management.get_admin_index,
|
||||||
|
Loading…
x
Reference in New Issue
Block a user