Skip to content

Commit

Permalink
Fixed #11842 -- django-admin.py now displays usage information if inv…
Browse files Browse the repository at this point in the history
…oked with no arguments. Thanks, bitprophet

git-svn-id: http://code.djangoproject.com/svn/django/trunk@12198 bcc190cf-cafb-0310-a4f2-bffc1f526a37
  • Loading branch information
adrianholovaty committed Jan 10, 2010
1 parent e1e4050 commit a4b0947
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions django/core/management/__init__.py
Expand Up @@ -358,8 +358,7 @@ def execute(self):
try: try:
subcommand = self.argv[1] subcommand = self.argv[1]
except IndexError: except IndexError:
sys.stderr.write("Type '%s help' for usage.\n" % self.prog_name) subcommand = 'help' # Display help if no arguments were given.
sys.exit(1)


if subcommand == 'help': if subcommand == 'help':
if len(args) > 2: if len(args) > 2:
Expand Down

0 comments on commit a4b0947

Please sign in to comment.