Management Commands¶
create_initial_data¶
This command creates initial data for the app using factories. You can run it like:
$ ./manage.py create_initial_data
If you want to remove all existing data in the database before creating
new one, specify --flush option:
$ ./manage.py create_initial_data --flush
If you want to specify any label to create any app specific data,
specify --app-label option:
$ ./manage.py create_initial_data --app-label jobs
Command-line options¶
- --flush¶
Remove existing data in the database before creating new data.
- --app-label <app_label>¶
Create initial data with the app_label provided.