Questions tagged «django-syncdb»

15
在运行Django的./manage.py syncdb时自动创建一个管理员用户
我的项目处于早期开发中。我经常删除数据库,然后manage.py syncdb从头开始运行以设置我的应用程序。 不幸的是,这总是弹出: You just installed Django's auth system, which means you don't have any superusers defined. Would you like to create one now? (yes/no): 然后,您提供了用户名,有效的电子邮件地址和密码。这很乏味。我已经厌倦了打字test\nx@x.com\ntest\ntest\n。 运行时,如何自动跳过此步骤并以编程方式创建用户manage.py syncdb?
By using our site, you acknowledge that you have read and understand our Cookie Policy and Privacy Policy.
Licensed under cc by-sa 3.0 with attribution required.