Fixed #5610 -- Added the ability for dumpdata to take individual model names, as well as entire applications. Thanks to David Reynolds for his work on this patch.

git-svn-id: http://code.djangoproject.com/svn/django/trunk@9921 bcc190cf-cafb-0310-a4f2-bffc1f526a37
This commit is contained in:
Russell Keith-Magee 2009-02-28 05:35:22 +00:00
parent b337884fcf
commit db2a95f6f5
4 changed files with 113 additions and 16 deletions

View file

@ -186,7 +186,7 @@ if you're ever curious to see the full list of defaults.
dumpdata
--------
.. django-admin:: dumpdata <appname appname ...>
.. django-admin:: dumpdata <appname appname appname.Model ...>
Outputs to standard output all data in the database associated with the named
application(s).
@ -228,6 +228,14 @@ directives::
easy for humans to read, so you can use the ``--indent`` option to
pretty-print the output with a number of indentation spaces.
.. versionadded: 1.1
In addition to specifying application names, you can provide a list of
individual models, in the form of ``appname.Model``. If you specify a model
name to ``dumpdata``, the dumped output will be restricted to that model,
rather than the entire application. You can also mix application names and
model names.
flush
-----