Find Docker Desktop executable path on Windows. Returns: Path to Docker Desktop.exe if found, None otherwise
()
| 140 | |
| 141 | |
| 142 | def _find_docker_desktop_executable() -> str | None: |
| 143 | """Find Docker Desktop executable path on Windows. |
| 144 | |
| 145 | Returns: |
| 146 | Path to Docker Desktop.exe if found, None otherwise |
| 147 | """ |
| 148 | docker_desktop_paths = [ |
| 149 | r"C:\Program Files\Docker\Docker\Docker Desktop.exe", |
| 150 | r"C:\Program Files (x86)\Docker\Docker\Docker Desktop.exe", |
| 151 | os.path.expanduser( |
| 152 | r"~\AppData\Local\Programs\Docker\Docker\Docker Desktop.exe" |
| 153 | ), |
| 154 | ] |
| 155 | |
| 156 | for docker_path in docker_desktop_paths: |
| 157 | if os.path.exists(docker_path): |
| 158 | return docker_path |
| 159 | |
| 160 | return None |
| 161 | |
| 162 | |
| 163 | def _kill_docker_desktop_windows() -> bool: |
no outgoing calls
no test coverage detected