zeit/z/versionCmd.go

23 lines
340 B
Go
Raw Permalink Normal View History

2020-10-11 00:58:14 +00:00
package z
import (
"fmt"
"github.com/spf13/cobra"
)
var VERSION string
func init() {
rootCmd.AddCommand(versionCmd)
}
var versionCmd = &cobra.Command{
Use: "version",
Short: "Display what Zeit it is",
Long: `The version of Zeit.`,
Run: func(cmd *cobra.Command, args []string) {
2020-10-15 20:38:11 +00:00
fmt.Println("zeit", VERSION)
2020-10-11 00:58:14 +00:00
},
}