In Django's bin
folder, names django-admin.py
which is separated by -
, while others such as easy_install
are isolated by underscore '_'. Django does not follow the PEP in naming, what is the particular advantage for this setting, or what kinds of unexpected problems will happen if Django's author names it as 'django_admin.py' instead of 'django-admin.py'
在Django的bin文件夹中,名称django-admin.pywhich用 - 分隔,而其他如easy_install则用下划线'_'隔离。 Django没有遵循PEP的命名,这个设置的特殊优势是什么,或者如果Django的作者将其命名为'django_admin.py'而不是'django-admin.py'会发生什么样的意外问题
1 个解决方案
#1
0
When you pip install django
, inside each virtual environment you create, the django-admin
is made to work as a CLI (command line interface) directly from your terminal. The convention of CLI command names is using dashes -
instead of _
underscores.
当你创建django时,在你创建的每个虚拟环境中,django-admin直接从你的终端作为CLI(命令行界面)工作。 CLI命令名称的约定是使用破折号 - 而不是_下划线。
Notice that when you execute django-admin
you're not executing it with python manage.py django-admin
but directly as django-admin
.
请注意,当您执行django-admin时,您不是使用python manage.py django-admin执行它,而是直接执行django-admin。
#1
0
When you pip install django
, inside each virtual environment you create, the django-admin
is made to work as a CLI (command line interface) directly from your terminal. The convention of CLI command names is using dashes -
instead of _
underscores.
当你创建django时,在你创建的每个虚拟环境中,django-admin直接从你的终端作为CLI(命令行界面)工作。 CLI命令名称的约定是使用破折号 - 而不是_下划线。
Notice that when you execute django-admin
you're not executing it with python manage.py django-admin
but directly as django-admin
.
请注意,当您执行django-admin时,您不是使用python manage.py django-admin执行它,而是直接执行django-admin。