( parsed: ParsedPowerShellCommand, scope: string, )
| 1531 | * Variable paths in PowerShell can have scopes like "env:PATH", "global:x". |
| 1532 | */ |
| 1533 | export function getVariablesByScope( |
| 1534 | parsed: ParsedPowerShellCommand, |
| 1535 | scope: string, |
| 1536 | ): ParsedVariable[] { |
| 1537 | const prefix = scope.toLowerCase() + ':' |
| 1538 | return parsed.variables.filter(v => v.path.toLowerCase().startsWith(prefix)) |
| 1539 | } |
| 1540 | |
| 1541 | /** |
| 1542 | * Check if any command in the parsed result matches a given name (case-insensitive). |
no outgoing calls
no test coverage detected