gouick/cmd/version.go
Matthieu 'JP' DERASSE 660a4ef162
Some checks failed
continuous-integration/drone/push Build is failing
fix(lint): Continue to apply linter recommandation
2022-08-03 11:17:15 +00:00

28 lines
461 B
Go

/*
Copyright © 2022 Matthieu Derasse <git@derasse.fr>
*/
package cmd
import (
"fmt"
"github.com/spf13/cobra"
)
// versionCmd represents the version command.
var versionCmd = &cobra.Command{
Use: "version",
Short: "Show gouick version",
Run: runVersion,
}
func init() {
rootCmd.AddCommand(versionCmd)
}
func runVersion(cmd *cobra.Command, args []string) {
// could probably have a look at runtime/debug
fmt.Printf("version: v%s\n", version)
}