sindresorhus / open

Open stuff like URLs, files, executables. Cross-platform.
MIT License
3.18k stars 219 forks source link

Running open module inside Ubuntu on wsl2 always opens browser in windows #293

Closed carylewis closed 1 year ago

carylewis commented 1 year ago

Now that wsl2 supports running graphical applications like firefox inside of the wsl2 environment, I was wondering if the current behaviour of the open module should be updated to allow users to specify which environment to open up urls in?

While the current open module behaviour probably makes sense for most users, it might be useful to allow the use of a ENV variable to allow the wsl2 based (e.g. Ubuntu), version of firefox to be used.

I am curious if anyone else thinks the same thing?

At the very least I think the README.md should call out how open works under wsl2.