Refinements on interactive shell
svn: r19677
This commit is contained in:
parent
685e4c2a46
commit
396f517548
@ -1,3 +1,9 @@
|
|||||||
|
#### This sets up Django so you can interact with it via the Python
|
||||||
|
#### command line.
|
||||||
|
#### Start with something like:
|
||||||
|
#### $ PYTHONPATH=.. python -i shell.py
|
||||||
|
#### >>> Person.objects.all()
|
||||||
|
|
||||||
from django.conf import settings
|
from django.conf import settings
|
||||||
import webapp.settings as default_settings
|
import webapp.settings as default_settings
|
||||||
try:
|
try:
|
||||||
@ -13,12 +19,13 @@ from webapp.reports import import_file
|
|||||||
from webapp.libdjango import DjangoInterface, totime, todate
|
from webapp.libdjango import DjangoInterface, totime, todate
|
||||||
from gen.datehandler import displayer, parser
|
from gen.datehandler import displayer, parser
|
||||||
import gen.lib
|
import gen.lib
|
||||||
|
import cli.user
|
||||||
|
|
||||||
db = DbDjango()
|
db = DbDjango()
|
||||||
dji = DjangoInterface()
|
dji = DjangoInterface()
|
||||||
dd = displayer.display
|
dd = displayer.display
|
||||||
dp = parser.parse
|
dp = parser.parse
|
||||||
|
|
||||||
#def Print(m):
|
#import_file(db,
|
||||||
# print m
|
# "/home/dblank/gramps/trunk/example/gramps/data.gramps",
|
||||||
#import_file(db, "/tmp/dblank-im_ged.ged", Print)
|
# cli.user.User())
|
||||||
|
Loading…
Reference in New Issue
Block a user