開発環境セットアップ¶
PR を開く前に英語ビルド・日本語ビルドをプレビューできるよう、sphinx-docs/ サイトをローカルにセットアップします。
前提条件¶
要件 |
バージョン |
備考 |
|---|---|---|
0.5+ |
Python パッケージ管理・仮想環境 |
|
Python |
3.12+ |
uv が自動でセットアップ |
Node.js |
24+ |
Pagefind 検索インデックス生成に使用 |
sphinx-docs/ 単体の作業では、rescript-tauri の他のツールチェーン(pnpm、ReScript 12 など)は 不要 です。
uv をインストール¶
# macOS / Linux
curl -LsSf https://astral.sh/uv/install.sh | sh
# Windows (PowerShell)
powershell -ExecutionPolicy ByPass -c "irm https://astral.sh/uv/install.ps1 | iex"
# Homebrew
brew install uv
リポジトリをクローン¶
git clone https://github.com/Nagatatz/rescript-tauri.git
cd rescript-tauri/sphinx-docs
依存関係をインストール¶
make install # uv sync (Python deps); npx will fetch Pagefind on first build
セットアップを確認¶
make html # English HTML build → _build/html/
make serve # Build EN+JA, assemble, and serve at localhost:8000
英語サイトのみのイテレーション時は、make liveserve で sphinx-autobuild を起動すると自動リロードが有効になります。
ファイル配置¶
パス |
役割 |
|---|---|
|
Sphinx 設定(テーマ、拡張、i18n、OpenGraph、Pagefind) |
|
uv 用の Python 依存マニフェスト |
|
全ビルドターゲット(ビルド を参照) |
|
英語ソースドキュメント |
|
日本語 |
|
テーマオーバーライドとアセット |
|
ビルド出力(gitignore 対象) |