Skip to content

Building 70 Projects ranging from beginner to advanced so anyone can — learn from, build upon, use as a reference, or even copy directly. Owned by my cybersecurity company 👇

409 B
Raw Blame
// ©AngelaMos | 2026
// version.go

package main

import (
	"fmt"

	"github.com/spf13/cobra"

	"github.com/CarterPerez-dev/nadezhda/internal/version"
)

var versionCmd = &cobra.Command{
	Use:   "version",
	Short: "Print version",
	RunE: func(cmd *cobra.Command, args []string) error {
		fmt.Printf("%s %s\n", version.Name, version.Version)
		return nil
	},
}

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