django1-創(chuàng)建并啟動(dòng)django工程

使用pycharm創(chuàng)建django工程

項(xiàng)目目錄結(jié)構(gòu)

 manage.py
 django1---工程主文件夾
        __init__.py
        settings.py
        urls.py
        wsgi.py
  templates  --模板文件夾

-manage.py 項(xiàng)目管理器 工具集 在pycharm面板的下方找到terminal 執(zhí)行 python manage.py 查看

Available subcommands:

[auth]
    changepassword
    createsuperuser

[contenttypes]
    remove_stale_contenttypes

[django]
    check
    compilemessages
    createcachetable
    dbshell
    diffsettings
    dumpdata
    flush
    inspectdb
    loaddata
    makemessages
    makemigrations
    migrate
    sendtestemail
    shell
    showmigrations
    sqlflush
    sqlmigrate
    sqlsequencereset
    squashmigrations
    startapp
    startproject
    test
    testserver

[sessions]
    clearsessions

[staticfiles]
    collectstatic
    findstatic
    runserver

啟動(dòng)工程
/Users/cx/.conda/envs/django1/bin/python manage.py runserver 8080

-wsgi.py WSGI (Python Web Server Gateway Interface)(python服務(wù)器網(wǎng)關(guān)接口) python應(yīng)用于web服務(wù)器之間的接口,
項(xiàng)目與外界交互的關(guān)鍵 不會(huì)用到不要?jiǎng)?不要管它
-urls.py 路由配置文件
-settings.py 核心配置文件

?著作權(quán)歸作者所有,轉(zhuǎn)載或內(nèi)容合作請聯(lián)系作者
平臺(tái)聲明:文章內(nèi)容(如有圖片或視頻亦包括在內(nèi))由作者上傳并發(fā)布,文章內(nèi)容僅代表作者本人觀點(diǎn),簡書系信息發(fā)布平臺(tái),僅提供信息存儲(chǔ)服務(wù)。

推薦閱讀更多精彩內(nèi)容