summaryrefslogtreecommitdiff
path: root/django
diff options
context:
space:
mode:
authorRaphael Michel <mail@raphaelmichel.de>2015-09-07 15:17:55 +0200
committerTim Graham <timograham@gmail.com>2015-09-08 08:41:03 -0400
commit1bbca7961cee20c4ddd453a7d74d316e84f4bbb5 (patch)
tree507f1df10ae0a5a050f7dae9f0e0b0a1247470a2 /django
parent25c157e4ccc27702883b0c3a53e0e9b44e19757d (diff)
Fixed #25350 -- Added alias --no-input for --noinput to management commands.
Diffstat (limited to 'django')
-rw-r--r--django/contrib/auth/management/commands/createsuperuser.py3
-rw-r--r--django/contrib/staticfiles/management/commands/collectstatic.py2
-rw-r--r--django/core/management/commands/flush.py3
-rw-r--r--django/core/management/commands/makemigrations.py3
-rw-r--r--django/core/management/commands/migrate.py3
-rw-r--r--django/core/management/commands/squashmigrations.py3
-rw-r--r--django/core/management/commands/test.py2
-rw-r--r--django/core/management/commands/testserver.py3
8 files changed, 14 insertions, 8 deletions
diff --git a/django/contrib/auth/management/commands/createsuperuser.py b/django/contrib/auth/management/commands/createsuperuser.py
index 558ee64d9f..56461cedfa 100644
--- a/django/contrib/auth/management/commands/createsuperuser.py
+++ b/django/contrib/auth/management/commands/createsuperuser.py
@@ -33,7 +33,8 @@ class Command(BaseCommand):
parser.add_argument('--%s' % self.UserModel.USERNAME_FIELD,
dest=self.UserModel.USERNAME_FIELD, default=None,
help='Specifies the login for the superuser.')
- parser.add_argument('--noinput', action='store_false', dest='interactive', default=True,
+ parser.add_argument('--noinput', '--no-input',
+ action='store_false', dest='interactive', default=True,
help=('Tells Django to NOT prompt the user for input of any kind. '
'You must use --%s with --noinput, along with an option for '
'any other required field. Superusers created with --noinput will '
diff --git a/django/contrib/staticfiles/management/commands/collectstatic.py b/django/contrib/staticfiles/management/commands/collectstatic.py
index 2d45648ba9..523f313c13 100644
--- a/django/contrib/staticfiles/management/commands/collectstatic.py
+++ b/django/contrib/staticfiles/management/commands/collectstatic.py
@@ -36,7 +36,7 @@ class Command(BaseCommand):
self.local = True
def add_arguments(self, parser):
- parser.add_argument('--noinput',
+ parser.add_argument('--noinput', '--no-input',
action='store_false', dest='interactive', default=True,
help="Do NOT prompt the user for input of any kind.")
parser.add_argument('--no-post-process',
diff --git a/django/core/management/commands/flush.py b/django/core/management/commands/flush.py
index 840c78486a..018c12ed96 100644
--- a/django/core/management/commands/flush.py
+++ b/django/core/management/commands/flush.py
@@ -17,7 +17,8 @@ class Command(BaseCommand):
'migrations. Does not achieve a "fresh install" state.')
def add_arguments(self, parser):
- parser.add_argument('--noinput', action='store_false', dest='interactive', default=True,
+ parser.add_argument('--noinput', '--no-input',
+ action='store_false', dest='interactive', default=True,
help='Tells Django to NOT prompt the user for input of any kind.')
parser.add_argument('--database', action='store', dest='database',
default=DEFAULT_DB_ALIAS,
diff --git a/django/core/management/commands/makemigrations.py b/django/core/management/commands/makemigrations.py
index da5a2bd257..d6af5cd4dc 100644
--- a/django/core/management/commands/makemigrations.py
+++ b/django/core/management/commands/makemigrations.py
@@ -29,7 +29,8 @@ class Command(BaseCommand):
help="Enable fixing of migration conflicts.")
parser.add_argument('--empty', action='store_true', dest='empty', default=False,
help="Create an empty migration.")
- parser.add_argument('--noinput', action='store_false', dest='interactive', default=True,
+ parser.add_argument('--noinput', '--no-input',
+ action='store_false', dest='interactive', default=True,
help='Tells Django to NOT prompt the user for input of any kind.')
parser.add_argument('-n', '--name', action='store', dest='name', default=None,
help="Use this name for migration file(s).")
diff --git a/django/core/management/commands/migrate.py b/django/core/management/commands/migrate.py
index 03e2a37ab1..9aa9c44206 100644
--- a/django/core/management/commands/migrate.py
+++ b/django/core/management/commands/migrate.py
@@ -33,7 +33,8 @@ class Command(BaseCommand):
'migration. Use the name "zero" to unapply all migrations.'
),
)
- parser.add_argument('--noinput', action='store_false', dest='interactive', default=True,
+ parser.add_argument('--noinput', '--no-input',
+ action='store_false', dest='interactive', default=True,
help='Tells Django to NOT prompt the user for input of any kind.')
parser.add_argument('--database', action='store', dest='database',
default=DEFAULT_DB_ALIAS, help='Nominates a database to synchronize. '
diff --git a/django/core/management/commands/squashmigrations.py b/django/core/management/commands/squashmigrations.py
index db55195187..39225c2d75 100644
--- a/django/core/management/commands/squashmigrations.py
+++ b/django/core/management/commands/squashmigrations.py
@@ -19,7 +19,8 @@ class Command(BaseCommand):
help='Migrations will be squashed until and including this migration.')
parser.add_argument('--no-optimize', action='store_true', dest='no_optimize', default=False,
help='Do not try to optimize the squashed operations.')
- parser.add_argument('--noinput', action='store_false', dest='interactive', default=True,
+ parser.add_argument('--noinput', '--no-input',
+ action='store_false', dest='interactive', default=True,
help='Tells Django to NOT prompt the user for input of any kind.')
def handle(self, **options):
diff --git a/django/core/management/commands/test.py b/django/core/management/commands/test.py
index 127ed5c846..0d084e1e91 100644
--- a/django/core/management/commands/test.py
+++ b/django/core/management/commands/test.py
@@ -32,7 +32,7 @@ class Command(BaseCommand):
def add_arguments(self, parser):
parser.add_argument('args', metavar='test_label', nargs='*',
help='Module paths to test; can be modulename, modulename.TestCase or modulename.TestCase.test_method')
- parser.add_argument('--noinput',
+ parser.add_argument('--noinput', '--no-input',
action='store_false', dest='interactive', default=True,
help='Tells Django to NOT prompt the user for input of any kind.'),
parser.add_argument('--failfast',
diff --git a/django/core/management/commands/testserver.py b/django/core/management/commands/testserver.py
index a629e7285a..3c14b26181 100644
--- a/django/core/management/commands/testserver.py
+++ b/django/core/management/commands/testserver.py
@@ -11,7 +11,8 @@ class Command(BaseCommand):
def add_arguments(self, parser):
parser.add_argument('args', metavar='fixture', nargs='*',
help='Path(s) to fixtures to load before running the server.')
- parser.add_argument('--noinput', action='store_false', dest='interactive', default=True,
+ parser.add_argument('--noinput', '--no-input',
+ action='store_false', dest='interactive', default=True,
help='Tells Django to NOT prompt the user for input of any kind.')
parser.add_argument('--addrport', default='',
help='Port number or ipaddr:port to run the server on.')