Skip to content

opencode: incorrect path for global AGENTS.md #19

Description

@kikoreis

These docs indicate ~/.opencode/AGENTS.md as the location for the global rules. It's actually ~/.config/opencode/AGENTS.md as per https://opencode.ai/docs/rules/#global

The diff:

diff --git a/docs/opencode/04-prompt-processing.md b/docs/opencode/04-prompt-processing.md
index 1234567..abcdefg 100644
--- a/docs/opencode/04-prompt-processing.md
+++ b/docs/opencode/04-prompt-processing.md
@@ -251,7 +251,7 @@ OpenCode searches for instruction files in this order:
 
 2. Global files (user's home directory):
-   - `~/.opencode/AGENTS.md`
+   - `~/.config/opencode/AGENTS.md`
    - `~/.claude/CLAUDE.md`
 
 3. Config instructions:
diff --git a/docs/opencode/05-system-prompts.md b/docs/opencode/05-system-prompts.md
index 1234567..abcdefg 100644
--- a/docs/opencode/05-system-prompts.md
+++ b/docs/opencode/05-system-prompts.md
@@ -44,7 +44,7 @@ OpenCode searches for agent guidelines in this order:
 - `CONTEXT.md` - Context and background
 
 **2. Global Files** (user's home directory):
-- `~/.opencode/AGENTS.md` - Global OpenCode instructions
+- `~/.config/opencode/AGENTS.md` - Global OpenCode instructions
 - `~/.claude/CLAUDE.md` - Global Claude instructions
 
 **3. Config Instructions** (from `.opencode/config.json`):
@@ -73,7 +73,7 @@ Project Root
 ...
 
-~/.opencode/AGENTS.md            # ← Global (fallback)
+~/.config/opencode/AGENTS.md            # ← Global (fallback)
 ~/.claude/CLAUDE.md              # ← Alternative global

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions