Files
jpictl/cmd/jpictl/main.go
T
amery 09bec11506 jpictl: add --version and version command
from `git describe` using go:generate and embed

Signed-off-by: Alejandro Mery <amery@jpi.io>
2024-03-02 23:15:56 +00:00

28 lines
382 B
Go

// Package main implements the jpictl command
package main
import (
_ "embed"
"github.com/spf13/cobra"
)
const (
// CmdName is the name of the executable
CmdName = "jpictl"
)
var (
rootCmd = &cobra.Command{
Use: CmdName,
Short: "control tool for jpi.cloud",
Version: version,
}
)
func main() {
if err := rootCmd.Execute(); err != nil {
fatal(err, "")
}
}