Ticket #11542: bshell.py

File bshell.py, 419 bytes (added by Seamus, 15 years ago)

manage.py command

Line 
1import os
2from django.core.management.base import NoArgsCommand
3from optparse import make_option
4
5class Command(NoArgsCommand):
6 help = "Runs the bpython interactive interpreter if it's installed."
7 requires_model_validation = False
8
9 def handle_noargs(self, **options):
10 from django.db.models.loading import get_models
11 loaded_models = get_models()
12 import bpython
13 bpython.embed()
Back to Top