WIP
This commit is contained in:
20
cmds/cmdbase/version.go
Normal file
20
cmds/cmdbase/version.go
Normal file
@@ -0,0 +1,20 @@
|
||||
package cmdbase
|
||||
|
||||
import (
|
||||
"fmt"
|
||||
|
||||
"github.com/spf13/cobra"
|
||||
|
||||
"github.com/safing/portmaster/base/info"
|
||||
)
|
||||
|
||||
var VersionCmd = &cobra.Command{
|
||||
Use: "version",
|
||||
Short: "Show version and related metadata.",
|
||||
RunE: Version,
|
||||
}
|
||||
|
||||
func Version(cmd *cobra.Command, args []string) error {
|
||||
fmt.Println(info.FullVersion())
|
||||
return nil
|
||||
}
|
||||
Reference in New Issue
Block a user