Files
cc-haha/docs/guide/quick-start.md
T
yuqei 124a18a4ec
Deploy VitePress Docs / build (push) Has been cancelled
Deploy VitePress Docs / deploy (push) Has been cancelled
Initialize cc-haha project mirror.
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-04-24 13:41:51 +08:00

1.7 KiB
Raw Blame History

快速开始

1. 安装 Bun

# macOS / Linux
curl -fsSL https://bun.sh/install | bash

# macOS (Homebrew)
brew install bun

# Windows (PowerShell)
powershell -c "irm bun.sh/install.ps1 | iex"

精简版 Linux 如提示 unzip is required,先运行 apt update && apt install -y unzip

2. 安装依赖并配置

bun install
cp .env.example .env
# 编辑 .env 填入你的 API Key,详见「环境变量」文档

环境变量的完整说明请参考 环境变量配置。

3. 启动

macOS / Linux

./bin/claude-haha                          # 交互 TUI 模式
./bin/claude-haha -p "your prompt here"    # 无头模式
./bin/claude-haha --help                   # 查看所有选项

Windows

前置要求:必须安装 Git for Windows

# PowerShell / cmd 直接调用 Bun
bun --env-file=.env ./src/entrypoints/cli.tsx

# 或在 Git Bash 中运行
./bin/claude-haha

4. 全局使用(可选)

将 bin/ 加入 PATH 后可在任意目录启动,详见 全局使用指南:

export PATH="$HOME/path/to/claude-code-haha/bin:$PATH"

5. 大型项目高效协作(强烈推荐)

如果你准备长期与 Claude 一起开发大型软件项目,建议固定采用这套协作流程:

它包含:

  • 项目第一天立项模板
  • 每日启动模板
  • 完整协作方法论
  • 高效开发节奏
  • 大型项目拆分方法

6. 降级模式

如果 Ink TUI 出现问题,可以使用降级 Recovery CLI 模式:

CLAUDE_CODE_FORCE_RECOVERY_CLI=1 ./bin/claude-haha