package temperature import ( "log" "os" "git.cryptic.systems/fh-trier/go-flucky/pkg/temperature" "github.com/spf13/cobra" ) var push bool var getTemperatureCmd = &cobra.Command{ Use: "get", Short: "get temperature from sensor", Args: cobra.ExactArgs(1), Run: func(cmd *cobra.Command, args []string) { if err := temperature.Get(os.Stdout, args[0], configDir); err != nil { log.Fatal(err) } }, } func init() { temperatureCmd.AddCommand(getTemperatureCmd) }