~/VibeHandbook
免費 PDF

15 · 10

回顧與練習

關鍵要點

  • 護欄讓 AI 得以全速衝刺,同時讓安全網接住跌落 — 它們讓你更快,而非更慢。
  • 測試、型別檢查和 lint 會免費幫你抓住錯誤;把它們接入 ,讓檢查自動執行。
  • 把 AI 的改動範圍限定得很窄,合併之前批判性地讀每一處 diff。
  • 紅色的檢查是資訊 — 在讓 AI “修復”它之前先分類(真正的 bug / 過時的測試 / 不穩定的檢查)。
  • 絕不上線你沒讀過的改動。

動手試試

在你的某個專案裡,設定一個你還沒有的自動檢查 — 一個測試、一個 linter,或一個型別檢查步驟 — 並把它加進 CI 工作流,讓它在每次 push 時執行。然後故意弄壞一個小東西,確認在你修復之前檢查會變紅。

Add a CI workflow to this repo that runs the test suite, the linter,
and the type checker on every push and pull request. Generate the
config, explain each step, and tell me how to read the output when a
check fails so I can tell a real bug from an out-of-date test.

想離線閱讀?

免費下載整本書的 PDF 或 EPUB。