(cmd: string)
| 36 | } |
| 37 | |
| 38 | function commandExists(cmd: string): boolean { |
| 39 | try { |
| 40 | execSync( |
| 41 | process.platform === 'win32' ? `where.exe ${cmd}` : `command -v ${cmd}`, |
| 42 | { stdio: 'ignore' }, |
| 43 | ); |
| 44 | return true; |
| 45 | } catch { |
| 46 | return false; |
| 47 | } |
| 48 | } |
| 49 | |
| 50 | /** |
| 51 | * Editor command configurations for different platforms. |
no outgoing calls
no test coverage detected