fix(core): Remove dead code and documentation related to the obsolete list tool. (#22672)

This commit is contained in:
Ariane Emory 2026-04-15 18:44:53 -04:00 committed by GitHub
parent 6bed7d469d
commit d2ea6700aa
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
60 changed files with 37 additions and 516 deletions

View file

@ -15,7 +15,6 @@ import { Permission } from "../../permission"
import { Tool } from "../../tool/tool"
import { GlobTool } from "../../tool/glob"
import { GrepTool } from "../../tool/grep"
import { ListTool } from "../../tool/ls"
import { ReadTool } from "../../tool/read"
import { WebFetchTool } from "../../tool/webfetch"
import { EditTool } from "../../tool/edit"
@ -103,14 +102,6 @@ function grep(info: ToolProps<typeof GrepTool>) {
})
}
function list(info: ToolProps<typeof ListTool>) {
const dir = info.input.path ? normalizePath(info.input.path) : ""
inline({
icon: "→",
title: dir ? `List ${dir}` : "List",
})
}
function read(info: ToolProps<typeof ReadTool>) {
const file = normalizePath(info.input.filePath)
const pairs = Object.entries(info.input).filter(([key, value]) => {
@ -420,7 +411,6 @@ export const RunCommand = cmd({
if (part.tool === "bash") return bash(props<typeof BashTool>(part))
if (part.tool === "glob") return glob(props<typeof GlobTool>(part))
if (part.tool === "grep") return grep(props<typeof GrepTool>(part))
if (part.tool === "list") return list(props<typeof ListTool>(part))
if (part.tool === "read") return read(props<typeof ReadTool>(part))
if (part.tool === "write") return write(props<typeof WriteTool>(part))
if (part.tool === "webfetch") return webfetch(props<typeof WebFetchTool>(part))