mirror of
https://github.com/django/django.git
synced 2025-08-08 12:58:37 +00:00
MERGED MAGIC-REMOVAL BRANCH TO TRUNK. This change is highly backwards-incompatible. Please read http://code.djangoproject.com/wiki/RemovingTheMagic for upgrade instructions.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@2809 bcc190cf-cafb-0310-a4f2-bffc1f526a37
This commit is contained in:
parent
d5dbeaa9be
commit
f69cf70ed8
366 changed files with 17833 additions and 11199 deletions
14
django/db/backends/postgresql/client.py
Normal file
14
django/db/backends/postgresql/client.py
Normal file
|
@ -0,0 +1,14 @@
|
|||
from django.conf import settings
|
||||
import os
|
||||
|
||||
def runshell():
|
||||
args = ['']
|
||||
args += ["-U%s" % settings.DATABASE_USER]
|
||||
if settings.DATABASE_PASSWORD:
|
||||
args += ["-W"]
|
||||
if settings.DATABASE_HOST:
|
||||
args += ["-h %s" % settings.DATABASE_HOST]
|
||||
if settings.DATABASE_PORT:
|
||||
args += ["-p %s" % settings.DATABASE_PORT]
|
||||
args += [settings.DATABASE_NAME]
|
||||
os.execvp('psql', args)
|
Loading…
Add table
Add a link
Reference in a new issue