(preset: string)
| 163 | export type ToolPreset = (typeof TOOL_PRESETS)[number] |
| 164 | |
| 165 | export function parseToolPreset(preset: string): ToolPreset | null { |
| 166 | const presetString = preset.toLowerCase() |
| 167 | if (!TOOL_PRESETS.includes(presetString as ToolPreset)) { |
| 168 | return null |
| 169 | } |
| 170 | return presetString as ToolPreset |
| 171 | } |
| 172 | |
| 173 | /** |
| 174 | * Get the list of tool names for a given preset |
no outgoing calls
no test coverage detected