Make the user agent configurable

This commit is contained in:
2021-02-10 22:16:15 -06:00
parent 8e7ff7f39a
commit b643635cf4
2 changed files with 18 additions and 3 deletions

View File

@ -11,6 +11,8 @@ import (
"github.com/BurntSushi/toml"
)
const userAgent = "lume"
func init() {
RegisterCommand("help", Command{
Func: HelpCmd,
@ -221,7 +223,7 @@ func Main(args []string) (int, error) {
command := args[1]
c := lifx.NewClient(config.AccessToken)
c := lifx.NewClientWithUserAgent(config.AccessToken, userAgent)
cmdArgs := CmdArgs{
Client: c,