慣性聚合 高效追讀感興趣之博客、新聞、科技資訊
閱原文 以慣性聚合開啟

推薦訂閱源

让小产品的独立变现更简单 - ezindie.com
让小产品的独立变现更简单 - ezindie.com
WordPress大学
WordPress大学
量子位
M
Microsoft Research Blog - Microsoft Research
Microsoft Azure Blog
Microsoft Azure Blog
Jina AI
Jina AI
罗磊的独立博客
V
Visual Studio Blog
Last Week in AI
Last Week in AI
阮一峰的网络日志
阮一峰的网络日志
IT之家
IT之家
aimingoo的专栏
aimingoo的专栏
雷峰网
雷峰网
酷 壳 – CoolShell
酷 壳 – CoolShell
美团技术团队
博客园 - 三生石上(FineUI控件)
OSCHINA 社区最新新闻
OSCHINA 社区最新新闻
MongoDB | Blog
MongoDB | Blog
小众软件
小众软件
IntelliJ IDEA : IntelliJ IDEA – the Leading IDE for Professional Development in Java and Kotlin | The JetBrains Blog
IntelliJ IDEA : IntelliJ IDEA – the Leading IDE for Professional Development in Java and Kotlin | The JetBrains Blog

DEV Community

The Treasure Hunt Engine Mistake That Brings Down Most Hytale Servers Speed Over Size: Why Gemini 3.5 Flash is the Most Important Update at Google I/O 2026 AI Daily Digest: May 24, 2026 — Agentic Dashboards, Cyber Defense & Unified Embodied AI CI/CD Pipelines in 2026: GitHub Actions vs GitLab CI vs CircleCI vs Jenkins From Cloud AI to Pocket AI: What Google I/O 2026 Means for Mobile Intelligence Universal SASE vs Single-Vendor SASE: Which Delivers Better Security & Performance? Autonomous Agents Need Receipts, Not Just Reasoning What 3.9M powerlifting records tell us about competition strategy — an EDA with Python Dev.to Article Draft #13 Beyond the Context Window: How to Build a Self-Improving AI Agent with Persistent Memory Full Agentic Stack - 5 Ideias da Arquitetura 'AI-First' que Vão Mudar a Forma Como Você Desenvolve Software Supply Chain Attacks + Stale Credentials: Why This Combination Is So Dangerous in 2026 Daily Briefing Platform Banning Agent PRs Won't Save Open Source Hitting Merge: Mentally Preparing for Your First Push to Production Learning Progress Pt.17 Monitoring Containers on AWS ECS with CloudWatch Tier 4 — Entity and Authority: Wikidata, KG, sameAs threading LocalFind Gemma — AI-Powered Semantic Search and Chat for Your Local Files AI-dy: On-Device Emergency First Aid with Gemma 4 Datrix: Chat With Your Data Using Gemma 4 — Charts, ML Models, No Code Understanding Reinforcement Learning with Human Feedback Part 4: Teaching Models Human Preferences The Architect’s Pivot: Mastering Parallel Agent Orchestration with Antigravity 2.0 Quidditch - Powered By PostgreSQL and ASP.NET Build a Database Connection Framework In 133 Lines Of Code How I mapped 600+ GPS audio-guides as a solo dev (and why I finally did it after 8 years) Installing Terminal & WSL (Windows Subsystem for Linux) A Floating Productivity Panel I Built for Android The Microsecond Lie: Why your Go timers are lying about the GPU Google used 6,000 open-source contributors then locked the door. Classic. Terceira semana tentando voltar ao mercado de trabalho How I turned a Python function into a web app in one decorator I Got Tired of Heavy Design Tools… So I Built My Own 😩 The Google I/O 2026 Moment That Quietly Changed How I See AI Getting Started: Run Your First Local LLM in 5 Minutes Building a 1% Fee Web3 Marketplace for Study Notes: Is a 5% Shift Sustainable? Full Agentic Stack - 5 Ideias da Arquitetura 'AI-First' que Vão Mudar a Forma Como Você Desenvolve Software Build Club Week Four: the part of Themis Lex I never explained I Tried Google Antigravity 2.0 Here's What It Actually Feels Like to Code With AI Agents By Isaac Yakubu | Google I/O 2026 Challenge Submission The growth quest picks what you avoid, not what you're already good at Firebase AI Logic's Template-Only Mode Is the Security Feature We Actually Needed Hardware Guide: What Do You Actually Need to Run Local LLMs? Constitutional Exception Committees: A Pattern for AI Agent Constraint Governance Veltrix's Treasure Hunt Engine: Optimized for Long-Term Survival, Not Just Scalability Open WebUI: Your Local ChatGPT Build a streaming UI without overcomplicating it The Cost of Kernel CVE Patching Frequency in SLA Commitments Gemma 4 Runs on a Raspberry Pi. Let That Sink In. The Git Filesystem - Recreating the Content-Addressable Database Why I Still Believe Our Event-Driven Architecture Was The Right Call For Veltrix
初识 Django:速成七成之奇术。其一:启程之始(今次为 Linux 之选)
Rouwel Ngach · 2026-05-24 · via DEV Community

Rouwel Ngacha

谨此声明(下文旨在仿照前文,然针对Linux操作系统。请尝试实施此法,若于汝机不效,则留言以俟吾寻解。)

今此篇,愿助不谙Django者,略明其用,速成项目之七成,若存若亡,瞬息可至。
今日之旨,在习始事之法。二文既成,当能疾行诸务。

首事当先,须知今世有Python之框架多矣(Flask,FastAPI)。择何者而用,恒在尔心,亦视尔所为之务之制限。

既明此理,吾辈当入焉。

第一步:务须下载Python。
吾之器,用Windows Subsystem For Linux(详于https://learn.microsoft.com/en-us/windows/wsl/install),此使吾得于机中运Linux Ubuntu之终端.

于安装,吾将用apt(Advanced Package Tool)以装python3.sudo apt update
sudo apt install python3

步骤二:谨察Django已装否。
安装 Django,吾将用 pip(Python 软件包安装器),是故汝须已下载并配置 Python 于路径之中。

吾欲再劝者,乃使用 Python 虚拟环境也。汝或未谙此道,然信吾言——未有良时,宜习此术。
其意在于,汝于项目环境之中,安装所有Python包,而只要初始化此环境,则所有项目依赖皆可运作(如Django、Pillow)。此法善乎?

吾辈处乎Linux之境,欲使虚拟环境得启,须下载所求之具(如venv),方能使之生效。
此乃因与Windows异,下载Python3时,venv包并非预装。
是故,若尔欲运行python3 -m venv MyProject
,必遭谬误。

Creating a python environment

故每欲用之包,皆须逐次安装。
1.sudo apt install python3-venv

自此,当创制并激活项目之境,用
python3 -m venv Projectsource Project/bin/activate

Creating the virtual environment

既入此境,當以pip安裝Django。

Installing Django

第三步:創建專案
欲啟專案,其令為django-admin startproject ProjectName

。既行此令,則生一匣,匣中有數預設之Python碼文在內。


(預設專案文件)

既成其事,当于其内初始化Django之应用。其令曰
python3 manage.py startapp <name_of_your_app>

既启汝之IDE,则知新项目之夹中,实藏数代码之文也。

第四步:运行服务器
此篇终章,专论运行之方。后继各篇,当深掘细研,创制小试之例,尽用 Django 之宏能,然此非今之务也。

欲运行服务器者,用之python3 manage.py runserver.

故尔若至localhost之8000端口,则得见之。

如是而已!汝已成功安装 Django,立项目,初始化应用,且使开发服务器运行(于 Linux)。
虽此或似微末之步骤,然此乃每 Django 之项目所筑之基石也。