Skip to content

Commit

Permalink
Added support for compilation on FreeBSD
Browse files Browse the repository at this point in the history
* To compile and run on FreeBSD
  • Loading branch information
florintanasa authored Dec 21, 2021
1 parent 4a6a5ff commit 417b8dc
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 0 deletions.
11 changes: 11 additions & 0 deletions db/embedded/embedded_freebsd.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
// +build freebsd

package embedded

import (
"os/exec"
)

func addSysProgAttrs(cmd *exec.Cmd) {
// freebsd users should not use embedded to begin with
}
2 changes: 2 additions & 0 deletions tools/tools.go
Original file line number Diff line number Diff line change
Expand Up @@ -177,6 +177,8 @@ func OpenRessource(path string, openWith bool) error {
switch runtime.GOOS {
case "linux":
cmd = exec.Command("xdg-open", path)
case "freebsd":
cmd = exec.Command("xdg-open", path)
case "windows":
if openWith {
cmd = exec.Command("openWith", path)
Expand Down

0 comments on commit 417b8dc

Please sign in to comment.