NewsBlur/utils/django_extensions/management/utils.py

8 lines
248 B
Python
Raw Normal View History

2009-07-22 04:24:24 +00:00
from django.conf import settings
import os
def get_project_root():
""" get the project root directory """
settings_mod = __import__(settings.SETTINGS_MODULE, {}, {}, [''])
return os.path.dirname(os.path.abspath(settings_mod.__file__))