---
title: "GEMINI.md (Gemini CLI): パスと形式 · DotsAgent"
description: "GEMINI.mdの配置場所、形式とfrontmatter、グローバル版とネストされた版の統合方法、読み込むツールを解説します。2026-10-01時点で確認済み。"
url: https://dotsagent.io/ja/instructions/files/gemini-md
---

GEMINI.md

# GEMINI.md (Gemini CLI): 配置場所とツールでの読み込み方

GEMINI.md は、Gemini CLI がすべての prompt とともに送信するコンテキストファイルです。context.fileName を設定すれば、AGENTS.md など別の名前のファイルも読み込めます。

## 配置場所

- グローバル: ~/.gemini/GEMINI.md。
- ワークスペースのディレクトリとその親ディレクトリにある GEMINI.md。
- ツールがアクセスするディレクトリとその祖先（信頼されたルートまで）で、必要に応じてその場で見つかった GEMINI.md。

## 形式

frontmatter なしの Markdown。Memory Import Processor を使い、@file.md で相対パスまたは絶対パスのファイルを読み込みます。ファイル名は context.fileName で設定でき、文字列またはリストを指定します。

`GEMINI.md`

```
# Project context

@./docs/architecture.md

## Commands

- Install: `uv sync`
- Test: `uv run pytest`
- Lint: `uv run ruff check .`

## Rules

- Target Python 3.13 with type hints on public functions.
- Keep database code in app/db/.
- Never run migrations against production.
```

## 優先順位と統合

ファイルはグローバル、ワークスペースと祖先ディレクトリ、その場で検出されたファイルの順に読み込まれます。すべて連結され、すべての prompt とともに送信されるため、上書きは行われません。

## 読み込むツール

| ツール | 対応状況 |
| --- | --- |
| [Gemini CLI](https://geminicli.com/docs/cli/gemini-md/) | 標準で対応しています。context.fileName でファイル名を変更したり、AGENTS.md を追加したりできます。/memory show と /memory reload で内容を確認できます。 |
| [GitHub Copilot](https://docs.github.com/en/copilot/how-tos/configure-custom-instructions/add-repository-instructions) | ルートの GEMINI.md を、AGENTS.md の代わりにエージェントの指示ファイルとして読み込みます。 |

## ヒント

- .gemini/settings.json で context.fileName を ["AGENTS.md", "GEMINI.md"] に設定すると、ほかのエージェントとファイルを共有できます。
- 読み込まれたファイルはすべての prompt とともに送信されるため、毎回モデルに渡す必要のない内容は削除してください。
- /memory show で Gemini CLI が実際に読み込んだ内容を確認し、編集後は /memory reload を実行します。

1つのフォームから、AGENTS.mdと5つのツールに対応するルールファイルを生成します。 [AGENTS.mdジェネレーターを開く →](https://dotsagent.io/ja/instructions)

## その他の指示ファイル

[AGENTS.md](https://dotsagent.io/ja/instructions/files/agents-md)

[CLAUDE.md](https://dotsagent.io/ja/instructions/files/claude-md)

[.cursor/rules/*.mdc](https://dotsagent.io/ja/instructions/files/cursor-rules)

[.github/copilot-instructions.md](https://dotsagent.io/ja/instructions/files/github-copilot-instructions)

[.devin/rules/*.md](https://dotsagent.io/ja/instructions/files/windsurf-rules)

[.clinerules/](https://dotsagent.io/ja/instructions/files/cline-rules)

[~/.openclaw/workspace/AGENTS.md](https://dotsagent.io/ja/instructions/files/openclaw-workspace)

## 出典

1. [geminicli.com](https://geminicli.com/docs/cli/gemini-md/)/docs/cli/gemini-md/

AIエージェント開発者向けの独立したリファレンスです。ここに記載されているいずれのベンダーとも提携していません。

© 2026 DotsAgent · 確認日: 2026年10月1日
