diff --git a/go.mod b/go.mod index fd50318..6f91693 100644 --- a/go.mod +++ b/go.mod @@ -3,12 +3,12 @@ module github.com/sachaos/todoist require ( github.com/BurntSushi/toml v0.3.1 // indirect github.com/fatih/color v1.7.0 + github.com/gofrs/uuid v3.2.0+incompatible github.com/mattn/go-colorable v0.0.9 // indirect github.com/mattn/go-isatty v0.0.4 // indirect github.com/mitchellh/go-homedir v1.0.0 // indirect github.com/pkg/browser v0.0.0-20180916011732-0a3d74bf9ce4 github.com/pmezard/go-difflib v1.0.0 // indirect - github.com/satori/go.uuid v1.2.0 github.com/spf13/viper v1.2.1 github.com/stretchr/testify v1.2.2 github.com/urfave/cli v1.20.0 diff --git a/go.sum b/go.sum index 62ab066..28dc765 100644 --- a/go.sum +++ b/go.sum @@ -6,6 +6,8 @@ github.com/fatih/color v1.7.0 h1:DkWD4oS2D8LGGgTQ6IvwJJXSL5Vp2ffcQg58nFV38Ys= github.com/fatih/color v1.7.0/go.mod h1:Zm6kSWBoL9eyXnKyktHP6abPY2pDugNf5KwzbycvMj4= github.com/fsnotify/fsnotify v1.4.7 h1:IXs+QLmnXW2CcXuY+8Mzv/fWEsPGWxqefPtCP5CnV9I= github.com/fsnotify/fsnotify v1.4.7/go.mod h1:jwhsz4b93w/PPRr/qN1Yymfu8t87LnFCMoQvtojpjFo= +github.com/gofrs/uuid v3.2.0+incompatible h1:y12jRkkFxsd7GpqdSZ+/KCs/fJbqpEXSGd4+jfEaewE= +github.com/gofrs/uuid v3.2.0+incompatible/go.mod h1:b2aQJv3Z4Fp6yNu3cdSllBxTCLRxnplIgP/c0N/04lM= github.com/hashicorp/hcl v1.0.0 h1:0Anlzjpi4vEasTeNFn2mLJgTSwt0+6sfsiTG8qcWGx4= github.com/hashicorp/hcl v1.0.0/go.mod h1:E5yfLk+7swimpb2L/Alb/PJmXilQ/rhwaUYs4T20WEQ= github.com/magiconair/properties v1.8.0 h1:LLgXmsheXeRoUOBOjtwPQCWIYqM/LU1ayDtDePerRcY= @@ -24,8 +26,6 @@ github.com/pkg/browser v0.0.0-20180916011732-0a3d74bf9ce4 h1:49lOXmGaUpV9Fz3gd7T github.com/pkg/browser v0.0.0-20180916011732-0a3d74bf9ce4/go.mod h1:4OwLy04Bl9Ef3GJJCoec+30X3LQs/0/m4HFRt/2LUSA= github.com/pmezard/go-difflib v1.0.0 h1:4DBwDE0NGyQoBHbLQYPwSUPoCMWR5BEzIk/f1lZbAQM= github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4= -github.com/satori/go.uuid v1.2.0 h1:0uYX9dsZ2yD7q2RtLRtPSdGDWzjeM3TbMJP9utgA0ww= -github.com/satori/go.uuid v1.2.0/go.mod h1:dA0hQrYB0VpLJoorglMZABFdXlWrHn1NEOzdhQKdks0= github.com/spf13/afero v1.1.2 h1:m8/z1t7/fwjysjQRYbP0RD+bUIF/8tJwPdEZsI83ACI= github.com/spf13/afero v1.1.2/go.mod h1:j4pytiNVoe2o6bmDsKpLACNPDBIoEAkihy7loJ1B0CQ= github.com/spf13/cast v1.2.0 h1:HHl1DSRbEQN2i8tJmtS6ViPyHx35+p51amrdsiTCrkg= diff --git a/lib/command.go b/lib/command.go index 0fdc1d0..0bec7ce 100644 --- a/lib/command.go +++ b/lib/command.go @@ -4,7 +4,7 @@ import ( "encoding/json" "net/url" - "github.com/satori/go.uuid" + "github.com/gofrs/uuid" ) type Command struct { @@ -17,9 +17,11 @@ type Command struct { type Commands []Command func NewCommand(command_type string, command_args interface{}) Command { + id, _ := uuid.NewV4() + tempid, _ := uuid.NewV4() return Command{ - UUID: uuid.NewV4().String(), - TempID: uuid.NewV4().String(), + UUID: id.String(), + TempID: tempid.String(), Type: command_type, Args: command_args, }