Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Allow an existing DJANGO_SETTINGS_MODULE to be used instead of overri…

…ding it
  • Loading branch information...
commit 996067281f49bd60d5bc99deeb9f33d5b4a99faa 1 parent 45276ff
@brosner brosner authored
Showing with 2 additions and 1 deletion.
  1. +2 −1  pinax/env.py
View
3  pinax/env.py
@@ -21,7 +21,8 @@ def setup_environ(dunder_file=None, project_path=None, relative_project_path=Non
# setup Django correctly (the hard-coding of settings is only temporary.
# carljm's proposal will remove that)
if settings_path is None:
- os.environ["DJANGO_SETTINGS_MODULE"] = "%s.settings" % project_name
+ if "DJANGO_SETTINGS_MODULE" not in os.environ:
+ os.environ["DJANGO_SETTINGS_MODULE"] = "%s.settings" % project_name
else:
os.environ["DJANGO_SETTINGS_MODULE"] = settings_path
Please sign in to comment.
Something went wrong with that request. Please try again.