basic common app packages
This commit is contained in:
21
open/linux.go
Normal file
21
open/linux.go
Normal file
@@ -0,0 +1,21 @@
|
||||
//go:build linux
|
||||
|
||||
// Copyright 2024 Patial Tech. All rights reserved.
|
||||
// Use of this source code is governed by a BSD-style
|
||||
// license that can be found in the LICENSE file.
|
||||
|
||||
package open
|
||||
|
||||
import (
|
||||
"os/exec"
|
||||
)
|
||||
|
||||
// http://sources.debian.net/src/xdg-utils
|
||||
|
||||
func open(input string) *exec.Cmd {
|
||||
return exec.Command("xdg-open", input)
|
||||
}
|
||||
|
||||
func openWith(input string, appName string) *exec.Cmd {
|
||||
return exec.Command(appName, input)
|
||||
}
|
Reference in New Issue
Block a user