mirror of
https://expo.survex.com/repositories/troggle/.git
synced 2024-11-26 01:01:53 +00:00
01073863f3
Copied from http://cucc@cucc.survex.com/svn/trunk/expoweb/troggle/, rev. 8043 by aaron @ 10/29/2008 7:35 AM
18 lines
590 B
Python
18 lines
590 B
Python
import os
|
|
os.environ['PYTHONPATH'] = 'c:\djangoprojects\verfification'
|
|
os.environ['DJANGO_SETTINGS_MODULE'] = 'settings'
|
|
from django.core import management
|
|
from django.db import connection
|
|
|
|
cursor = connection.cursor()
|
|
cursor.execute("drop database verification")
|
|
cursor.execute("create database verification")
|
|
cursor.execute("use verification")
|
|
management.call_command('syncdb')
|
|
from django.contrib.auth.models import User
|
|
user = User.objects.create_user('m', 'm@m.com', 'm')
|
|
user.is_staff = True
|
|
user.is_superuser = True
|
|
user.save()
|
|
#management.call_command('runserver')
|