bitovi / launchpad

NodeJS Browser Launcher
MIT License
46 stars 28 forks source link

Finding Edge Fails when Edge DevTools are enabled #113

Open zevisert opened 5 years ago

zevisert commented 5 years ago

When windows getEdgeDirectory runs, this filter

https://github.com/bitovi/launchpad/blob/b1d254a9fe405691c7a13d0c4de8b39edff4f313/lib/local/platform/windows.js#L90-L91

results in inclusion of both these paths:

On my system the DevToolsClient folder comes first, so launchpad returns that path right after.

https://github.com/bitovi/launchpad/blob/b1d254a9fe405691c7a13d0c4de8b39edff4f313/lib/local/platform/windows.js#L96

The DevToolsClient folder doesn't contain a copy of MicrosoftEdge.exe so launchpad fails to detect edge on my system.

Easy fix

chasenlehara commented 5 years ago

Thanks for filing this issue @zevisert!

I see this function being used here: https://github.com/bitovi/launchpad/blob/b1d254a9fe405691c7a13d0c4de8b39edff4f313/lib/local/platform/windows.js#L41

I wonder if it should check for MicrosoftEdge.exe in each of the folders it gets, and then select the first one if there are multiple?