zeit/z/version.go

23 lines
340 B
Go
Raw 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) {
fmt.Println("Zeit", VERSION)
},
}