MCPcopy Create free account
hub / github.com/codeaashu/claude-code / isItemTypeParamAbbrev

Function isItemTypeParamAbbrev

src/tools/PowerShellTool/modeValidation.ts:64–69  ·  view source on GitHub ↗

* Check if a lowered, dash-normalized arg (colon-value stripped) is an * unambiguous PowerShell abbreviation of New-Item's -ItemType or -Type param. * Min prefixes: `-it` (avoids ambiguity with other New-Item params), `-ty` * (avoids `-t` colliding with `-Target`).

(p: string)

Source from the content-addressed store, hash-verified

62 * (avoids `-t` colliding with `-Target`).
63 */
64function isItemTypeParamAbbrev(p: string): boolean {
65 return (
66 (p.length >= 3 && '-itemtype'.startsWith(p)) ||
67 (p.length >= 3 && '-type'.startsWith(p))
68 )
69}
70
71/**
72 * Detects New-Item creating a filesystem link (-ItemType SymbolicLink /

Callers 1

isSymlinkCreatingCommandFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected