This repository was archived by the owner on Jan 17, 2021. It is now read-only.
This repository was archived by the owner on Jan 17, 2021. It is now read-only.
Windows WSL/MSYS path issues (fixes pr#127) #129
Closed
Description
I have narrowed down my error for to specifcally this
msysPath = "/c/'Program Files (x86)'/Google/Chrome/Application/chrome.exe"
(x86)
It seems to thing that it is trying to leave exec.Command()
by using the )
from (x86)
func openBrowser(url string) {
var openCmd *exec.Cmd
const (
macPath = "/Applications/Google Chrome.app/Contents/MacOS/Google Chrome"
wslPath = "/mnt/c/Program Files (x86)/Google/Chrome/Application/chrome.exe"
msysPath = "/c/'Program Files (x86)'/Google/Chrome/Application/chrome.exe"
)
switch {
case commandExists("google-chrome"):
openCmd = exec.Command("google-chrome", chromeOptions(url)...)
case commandExists("google-chrome-stable"):
openCmd = exec.Command("google-chrome-stable", chromeOptions(url)...)
case commandExists("chromium"):
openCmd = exec.Command("chromium", chromeOptions(url)...)
case commandExists("chromium-browser"):
openCmd = exec.Command("chromium-browser", chromeOptions(url)...)
case pathExists(macPath):
openCmd = exec.Command(macPath, chromeOptions(url)...)
case pathExists(wslPath):
openCmd = exec.Command(wslPath, chromeOptions(url)...)
case pathExists(msysPath):
openCmd = exec.Command(msysPath, chromeOptions(url)...)
default:
err := browser.OpenURL(url)
if err != nil {
flog.Error("failed to open browser: %v", err)
}
return
}
}
the most annoying thing is, I KNOW THE DAMNED ERROR, I dont know how to fracking FIX IT!
THis is what is holding back #127 from being pushed to mainstream
Metadata
Metadata
Assignees
Labels
No labels