question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Update opn for WSL/Bash on Windows support

See original GitHub issue

Issue details

opn is required with 4.0.2 by browser-sync (used for opening the browser automatically). However, this version doesn’t work in WSL/Bash on Windows. The latest version works correctly in WSL/Bash on Windows. It would be nice if browser-sync could update opn to its recent release version 5.3.0.

Steps to reproduce/test case

Start browser-sync. Notice this warning:

[Browsersync] Couldn't open browser (if you are using BrowserSync in a headless environment, you might want to set the open option to false)

Please specify which version of Browsersync, node and npm you’re running

  • Browsersync [2.23.6]
  • Node [v8.11.3]
  • Npm [5.6.0]

Affected platforms

  • linux
  • windows
  • other: (Windows) WSL/Bash on Windows
  • OS X
  • freebsd
  • solaris

Browsersync use-case

  • API
  • Gulp
  • Grunt
  • CLI
  • webpack

for all other use-cases, (gulp, grunt etc), please show us exactly how you’re using Browsersync

(not related to this general issue with outdated opn)

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Reactions:1
  • Comments:9 (3 by maintainers)

github_iconTop GitHub Comments

2reactions
shakyShanecommented, Aug 26, 2018

yeah I’ll get a release out in the next few hours

2reactions
Kurzdorcommented, Jul 14, 2018

You can use special BS version with updated opn package Here is the GitHub repo: https://github.com/Kurzdor/browser-sync And here is the npm package page: https://www.npmjs.com/package/browser-sync-wsl Tested it on my machine, works greatly. I will delete this BS version when devs will fix this issue. Thanks a lot!

Read more comments on GitHub >

github_iconTop Results From Across the Web

Install Linux on Windows with WSL - Microsoft Learn
Upgrade version from WSL 1 to WSL 2 ... New Linux installations, installed using the wsl --install command, will be set to WSL...
Read more >
How to Enable the Linux Bash Shell on Windows 10 [WSL 2]
1. First of all, we need to enable the “Windows Subsystem for Linux” feature. · 2. Next, scroll down and enable “Windows Subsystem...
Read more >
How to Install and Use the Linux Bash Shell on Windows 10
You can launch your installed Linux environment by running the wsl command. If you have multiple Linux distributions installed, you can choose ...
Read more >
How to Install WSL 2 on Windows 10 (Updated) - OMG! Ubuntu!
WSL 2 is a major upgrade over the original version of WSL Microsoft introduced in 2017. More than a mere version bump, WSL...
Read more >
The Ultimate Guide to Windows Subsystem for Linux ...
To find the Windows 10 file system from Linux, open up WSL in Windows. WSL will then bring up a bash terminal. This...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found