Changeset 6622
- Timestamp:
- 10/27/07 11:09:52 (1 year ago)
- Files:
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
django/trunk/django/core/management/commands/startapp.py
r6621 r6622 1 from django.core.management.base import copy_helper, CommandError, LabelCommand2 1 import os 3 2 3 from django.core.management.base import copy_helper, CommandError, LabelCommand 4 4 5 class Command(LabelCommand): 5 help = "Creates a Django app directory structure for the given app name in the current directory." 6 help = ("Creates a Django app directory structure for the given app name" 7 " in the current directory.") 6 8 args = "[appname]" 7 9 label = 'application name' … … 20 22 project_name = os.path.basename(directory) 21 23 if app_name == project_name: 22 raise CommandError("You cannot create an app with the same name (%r) as your project." % app_name) 24 raise CommandError("You cannot create an app with the same name" 25 " (%r) as your project." % app_name) 23 26 copy_helper(self.style, 'app', app_name, directory, project_name) 24 27 25 28 class ProjectCommand(Command): 26 help = "Creates a Django app directory structure for the given app name in this project's directory." 29 help = ("Creates a Django app directory structure for the given app name" 30 " in this project's directory.") 27 31 28 32 def __init__(self, project_directory):
