Skip to content

Commit

Permalink
Merge pull request #2 from scfarley/main
Browse files Browse the repository at this point in the history
Add a default browser Open() for UNIX systems other than Linux and Darwin
  • Loading branch information
kpym authored Feb 17, 2024
2 parents 2b8c100 + cb4e1d6 commit 2d78172
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions internal/browser/browser_unix.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
//go:build !darwin && !linux && !windows

package browser

import (
"os/exec"
)

// open the browser
func Open(url string) (err error) {
return exec.Command("xdg-open", url).Start()
}

0 comments on commit 2d78172

Please sign in to comment.