pull/10678/head
Aiden Cline 2026-01-26 08:44:29 -05:00
parent 67148a410c
commit e2d9638b3c
3 changed files with 24 additions and 5 deletions

View File

@ -1705,10 +1705,25 @@ function Glob(props: ToolProps<typeof GlobTool>) {
}
function Read(props: ToolProps<typeof ReadTool>) {
const { theme } = useTheme()
const loaded = createMemo(() => {
if (props.part.state.status !== "completed") return
if (props.part.state.time.compacted) return
return props.metadata.loaded
})
return (
<InlineTool icon="→" pending="Reading file..." complete={props.input.filePath} part={props.part}>
Read {normalizePath(props.input.filePath!)} {input(props.input, ["filePath"])}
</InlineTool>
<>
<InlineTool icon="→" pending="Reading file..." complete={props.input.filePath} part={props.part}>
Read {normalizePath(props.input.filePath!)} {input(props.input, ["filePath"])}
</InlineTool>
<Show when={loaded()}>
<box paddingLeft={3}>
<text paddingLeft={3} fg={theme.textMuted}>
Loaded {normalizePath(loaded()!)}
</text>
</box>
</Show>
</>
)
}

View File

@ -10,7 +10,11 @@ import type { MessageV2 } from "./message-v2"
const log = Log.create({ service: "instruction" })
const FILES = ["AGENTS.md", "CLAUDE.md", "CONTEXT.md"]
const FILES = [
"AGENTS.md",
"CLAUDE.md",
"CONTEXT.md", // deprecated
]
function globalFiles() {
const files = [path.join(Global.Path.config, "AGENTS.md")]

View File

@ -88,7 +88,7 @@ export OPENCODE_DISABLE_CLAUDE_CODE_SKILLS=1 # Disable only .claude/skills
When opencode starts, it looks for rule files in this order:
1. **Local files** by traversing up from the current directory (`AGENTS.md`, `CLAUDE.md`, or `CONTEXT.md`)
1. **Local files** by traversing up from the current directory (`AGENTS.md`, `CLAUDE.md`)
2. **Global file** at `~/.config/opencode/AGENTS.md`
3. **Claude Code file** at `~/.claude/CLAUDE.md` (unless disabled)