22 lines
497 B
Go
22 lines
497 B
Go
// Copyright (c) 2024 Joshua Rich <joshua.rich@gmail.com>
|
|
//
|
|
// This software is released under the MIT License.
|
|
// https://opensource.org/licenses/MIT
|
|
|
|
package cmd
|
|
|
|
import (
|
|
"github.com/rs/zerolog/log"
|
|
"github.com/spf13/cobra"
|
|
|
|
"github.com/joshuar/go-hass-agent/internal/agent/config"
|
|
)
|
|
|
|
var versionCmd = &cobra.Command{
|
|
Use: "version",
|
|
Short: "Print the version number",
|
|
Run: func(cmd *cobra.Command, args []string) {
|
|
log.Info().Msgf("%s: %s", config.AppName, config.AppVersion)
|
|
},
|
|
}
|