cmd/version.go
author Mikael Berthe <mikael@lilotux.net>
Sat, 22 Apr 2017 14:58:57 +0200
changeset 8 cde24b04e16d
parent 3 71812d67a16b
child 25 280b34baee60
permissions -rw-r--r--
Bump version to 0.2.0

// Copyright © 2017 Mikael Berthe <mikael@lilotux.net>
//
// Licensed under the MIT license.
// Please see the LICENSE file is this directory.

package cmd

import (
	"fmt"

	"github.com/spf13/cobra"
)

// VERSION of the madonctl application
var VERSION = "0.2.0"

var versionCmd = &cobra.Command{
	Use:   "version",
	Short: "Display " + AppName + " version",
	Run: func(cmd *cobra.Command, args []string) {
		fmt.Printf("This is %s version %s\n", AppName, VERSION)
	},
}

func init() {
	RootCmd.AddCommand(versionCmd)
}