async function isShellAvailable(shellPath) {
  try {
    // For Windows shells, use different detection methods
    if (shellPath === 'cmd' || shellPath === 'cmd.exe') {
      // On Windows, cmd should always be available
      if (os.platform() === 'win32') {
        return true;
      }
      return false;
    }
    
    if (shellPath === 'pwsh' || shellPath === 'powershell') {
      // Check if PowerShell is available
      try {
        const result = await executeCommand(`${shellPath} -Command "Get-Host"`, 2000);
        return result.content && result.content[0] && !result.content[0].text.includes('not found');
      } catch (error) {
        return false;
      }
    }
    
    // For Unix shells, check if the file exists and is executable
    try {
      const result = await executeCommand(`test -x "${shellPath}" && echo "available"`, 2000);
      return result.content && result.content[0] && result.content[0].text.includes('available');
    } catch (error) {
      return false;
    }
  } catch (error) {
    console.log(`Could not check availability of ${shellPath}: ${error.message}`);
    return false;
  }
}
Check if a shell is available on the system