diff --git a/cmd/device-register/main.go b/cmd/device-register/main.go index b349add..ac1e289 100644 --- a/cmd/device-register/main.go +++ b/cmd/device-register/main.go @@ -31,7 +31,6 @@ import ( "github.com/TheCacophonyProject/modemd/connrequester" arg "github.com/alexflint/go-arg" petname "github.com/dustinkirkland/golang-petname" - "github.com/sirupsen/logrus" ) const ( @@ -46,7 +45,7 @@ const ( ) var version = "" -var log *logrus.Logger +var log = logging.NewLogger("info") type Args struct { Reboot bool `arg:"-r,--reboot" help:"reboot device after registering"` @@ -99,8 +98,6 @@ func main() { func runMain() error { args := procArgs() - log = logging.NewLogger(args.LogLevel) - log.Printf("Running version: %s", version) cr := connrequester.NewConnectionRequester() diff --git a/go.mod b/go.mod index 554c573..846a378 100644 --- a/go.mod +++ b/go.mod @@ -4,13 +4,12 @@ go 1.22.3 require ( github.com/TheCacophonyProject/event-reporter/v3 v3.6.1 - github.com/TheCacophonyProject/go-api v1.2.0 + github.com/TheCacophonyProject/go-api v1.2.2 github.com/TheCacophonyProject/go-config v1.9.4 - github.com/TheCacophonyProject/go-utils v0.1.1 + github.com/TheCacophonyProject/go-utils v0.1.3 github.com/TheCacophonyProject/modemd v1.6.1 github.com/alexflint/go-arg v1.4.3 github.com/dustinkirkland/golang-petname v0.0.0-20231002161417-6a283f1aaaf2 - github.com/sirupsen/logrus v1.9.3 ) require ( @@ -23,6 +22,7 @@ require ( github.com/magiconair/properties v1.8.5 // indirect github.com/mitchellh/mapstructure v1.4.2 // indirect github.com/pelletier/go-toml v1.9.4 // indirect + github.com/sirupsen/logrus v1.9.3 // indirect github.com/spf13/afero v1.6.0 // indirect github.com/spf13/cast v1.4.1 // indirect github.com/spf13/jwalterweatherman v1.1.0 // indirect diff --git a/go.sum b/go.sum index 2873f95..ab4a934 100644 --- a/go.sum +++ b/go.sum @@ -53,14 +53,14 @@ github.com/TheCacophonyProject/event-reporter/v3 v3.6.1 h1:I8RmEHHnAhp1hL9yiGfyf github.com/TheCacophonyProject/event-reporter/v3 v3.6.1/go.mod h1:WTppJtTBxduasM1Or5SAh4Mm0YrTDnprOChjnGYgyEI= github.com/TheCacophonyProject/go-api v0.0.0-20190923033957-174cea2ac81c/go.mod h1:FfMpa4cFhNXQ9tuKG18HO6yLExezcJhzjUjBOFocrQw= github.com/TheCacophonyProject/go-api v1.0.4/go.mod h1:F7UUNgsLhbw7hsiNBMRB9kQz9uXXosVmNToqImz7EA8= -github.com/TheCacophonyProject/go-api v1.2.0 h1:5cEUlv3Xe8T4SuLmIPK2ppkPt/Mi41OSvp/vCPPUxuY= -github.com/TheCacophonyProject/go-api v1.2.0/go.mod h1:F7UUNgsLhbw7hsiNBMRB9kQz9uXXosVmNToqImz7EA8= +github.com/TheCacophonyProject/go-api v1.2.2 h1:lXV2/upgA6lgLWOuTMRJoTjMXxlSveN9v8Dr3mvYqPM= +github.com/TheCacophonyProject/go-api v1.2.2/go.mod h1:innR3kf5xnua2wbnLvOudI13j2TU1sGY1dxJQJLRZkI= github.com/TheCacophonyProject/go-config v0.0.0-20190922224052-7c2a21bc6b88/go.mod h1:gPUJLVu408NRz9/P3BrsxzOzLc+KJLrv+jVdDw3RI0Y= github.com/TheCacophonyProject/go-config v1.9.0/go.mod h1:+y80PSRZudMYuVrYTGOvzc66NxVJWKS4TuU442vmvhY= github.com/TheCacophonyProject/go-config v1.9.4 h1:osO8lizzcxxWuy88wewBVdjESsFwwKK1VIxEe9bb+LM= github.com/TheCacophonyProject/go-config v1.9.4/go.mod h1:XZwQmNl2wQXhYR18RQtwZ6LwFwgAx73yzJfymYLz68s= -github.com/TheCacophonyProject/go-utils v0.1.1 h1:VOt9EphEqRUYMqKJlJeliIarIMlCVKYGb1fdqM6b4YM= -github.com/TheCacophonyProject/go-utils v0.1.1/go.mod h1:jZPUZ4GtYVxnlTtqiYKMFWDT//kmxdbwjLW3HCyCmCE= +github.com/TheCacophonyProject/go-utils v0.1.3 h1:DSuDeJz7ZM00yQRLsoukWH0fnC+8X8+ziYxOl6l3wEY= +github.com/TheCacophonyProject/go-utils v0.1.3/go.mod h1:jZPUZ4GtYVxnlTtqiYKMFWDT//kmxdbwjLW3HCyCmCE= github.com/TheCacophonyProject/modemd v0.0.0-20190605010435-ae5b0f2eb760/go.mod h1:bfwJ/WcvDY9XtHKC5tcRfVrU8RWaW8DLYAAUfsrJr/4= github.com/TheCacophonyProject/modemd v1.6.0/go.mod h1:0M7yJCdqhvoI5dVeDjOH6vsmbOBr1YhZ8DpAK4AkOA0= github.com/TheCacophonyProject/modemd v1.6.1 h1:YNWWNcos1uz+BVYx0qcvpN7DvQPx+Q2LMAZixy5Dqnc=