-
Notifications
You must be signed in to change notification settings - Fork 0
/
manage.py
executable file
·32 lines (25 loc) · 1.06 KB
/
manage.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
#!/usr/bin/env python
"""
Start the drneutron server.
Starts the server in debug mode. Set "DJANGO_PRODUCTION=1" in os.environ to
start in production mode. This is done automatically in apps/wsgi.py.
Use ./resetdb.sh to clear the debug database (resetdb.bat on windows).
Note: if you
"""
import sys, os
sys.dont_write_bytecode = True
# diddle the path so it includes the dependencies
ROOT=os.path.abspath(os.path.dirname(__file__))
sys.path.insert(0, os.path.join(ROOT, 'repos', 'bumps'))
sys.path.insert(0, os.path.join(ROOT, 'repos', 'django-tracks'))
sys.path.insert(0, os.path.join(ROOT, 'repos', 'dataflow'))
sys.path.insert(0, os.path.join(ROOT, 'repos', 'ncnr_reduction'))
sys.path.insert(0, os.path.join(ROOT, 'repos', 'scattio', 'python'))
sys.path.insert(0, ROOT)
# tell django which settings file to use
os.environ.setdefault("DJANGO_SETTINGS_MODULE", "website.settings")
# Run django
if __name__ == "__main__":
from django.core.management import execute_from_command_line
#print("=== path\n%s\n==="%("\n".join(sys.path)))
execute_from_command_line(sys.argv)