1
0
mirror of https://github.com/django/django.git synced 2025-05-23 07:16:29 +00:00
django/django/__init__.py
Aymeric Augustin 1c242a297b Merged Apps.populate_apps() and populate_models().
After the recent series of refactorings, there's no reason to keep
two distinct methods.

Refs #21681.
2013-12-30 23:18:22 +01:00

17 lines
545 B
Python

VERSION = (1, 7, 0, 'alpha', 0)
def get_version(*args, **kwargs):
# Don't litter django/__init__.py with all the get_version stuff.
# Only import if it's actually called.
from django.utils.version import get_version
return get_version(*args, **kwargs)
def setup():
# Configure the settings (this happens as a side effect of accessing
# INSTALLED_APPS or any other setting) and populate the app registry.
from django.apps import apps
from django.conf import settings
apps.populate(settings.INSTALLED_APPS)