MCPcopy Create free account
hub / github.com/diillson/chatcli / extractPathArg

Function extractPathArg

cli/plugins/args_extract.go:166–168  ·  view source on GitHub ↗

extractPathArg is the analog for file-oriented plugins (@coder read / future Read tool). It accepts both "file" and "path" because both appear in the codebase's existing schemas.

(args []string)

Source from the content-addressed store, hash-verified

164// future Read tool). It accepts both "file" and "path" because both
165// appear in the codebase's existing schemas.
166func extractPathArg(args []string) string {
167 return extractStringArg(args, "file", "path", "filepath")
168}
169
170// extractNestedArg pulls a string from inside the `args` field of the
171// @coder envelope (or any other plugin that uses the same nested shape).

Callers 2

DescribeCallMethod · 0.85

Calls 1

extractStringArgFunction · 0.85

Tested by 1