diff --git a/.travis.yml b/.travis.yml index 53c6a57..548fb5c 100644 --- a/.travis.yml +++ b/.travis.yml @@ -3,10 +3,9 @@ sudo: required language: go services: - mysql -before_install: -- go get github.com/golang/dep/cmd/dep install: -- dep ensure +- go mod download +- go install before_script: - go build -ldflags="-X main.Version=$TRAVIS_TAG" - go get github.com/alecthomas/gometalinter diff --git a/Gopkg.lock b/Gopkg.lock deleted file mode 100644 index 3847e18..0000000 --- a/Gopkg.lock +++ /dev/null @@ -1,66 +0,0 @@ -# This file is autogenerated, do not edit; changes may be undone by the next 'dep ensure'. - - -[[projects]] - name = "github.com/davecgh/go-spew" - packages = ["spew"] - revision = "8991bc29aa16c548c550c7ff78260e27b9ab7c73" - version = "v1.1.1" - -[[projects]] - name = "github.com/go-sql-driver/mysql" - packages = ["."] - revision = "d523deb1b23d913de5bdada721a6071e71283618" - version = "v1.4.0" - -[[projects]] - name = "github.com/kelseyhightower/envconfig" - packages = ["."] - revision = "f611eb38b3875cc3bd991ca91c51d06446afa14c" - version = "v1.3.0" - -[[projects]] - name = "github.com/naoina/go-stringutil" - packages = ["."] - revision = "6b638e95a32d0c1131db0e7fe83775cbea4a0d0b" - version = "v0.1.0" - -[[projects]] - name = "github.com/naoina/toml" - packages = [ - ".", - "ast" - ] - revision = "e6f5723bf2a66af014955e0888881314cf294129" - version = "v0.1.1" - -[[projects]] - name = "github.com/pmezard/go-difflib" - packages = ["difflib"] - revision = "792786c7400a136282c1664665ae0a8db921c6c2" - version = "v1.0.0" - -[[projects]] - name = "github.com/rs/cors" - packages = ["."] - revision = "3fb1b69b103a84de38a19c3c6ec073dd6caa4d3f" - version = "v1.5.0" - -[[projects]] - name = "github.com/stretchr/testify" - packages = ["assert"] - revision = "f35b8ab0b5a2cef36673838d662e249dd9c94686" - version = "v1.2.2" - -[[projects]] - name = "google.golang.org/appengine" - packages = ["cloudsql"] - revision = "b1f26356af11148e710935ed1ac8a7f5702c7612" - version = "v1.1.0" - -[solve-meta] - analyzer-name = "dep" - analyzer-version = 1 - inputs-digest = "356466433892643a1327fd5f9cdaddb4ed63ce9d8c8fc4ebee8f6aa0fa66b56a" - solver-name = "gps-cdcl" - solver-version = 1 diff --git a/Gopkg.toml b/Gopkg.toml deleted file mode 100644 index 7ad7ea9..0000000 --- a/Gopkg.toml +++ /dev/null @@ -1,50 +0,0 @@ -# Gopkg.toml example -# -# Refer to https://github.com/golang/dep/blob/master/docs/Gopkg.toml.md -# for detailed Gopkg.toml documentation. -# -# required = ["github.com/user/thing/cmd/thing"] -# ignored = ["github.com/user/project/pkgX", "bitbucket.org/user/project/pkgA/pkgY"] -# -# [[constraint]] -# name = "github.com/user/project" -# version = "1.0.0" -# -# [[constraint]] -# name = "github.com/user/project2" -# branch = "dev" -# source = "github.com/myfork/project2" -# -# [[override]] -# name = "github.com/x/y" -# version = "2.4.0" -# -# [prune] -# non-go = false -# go-tests = true -# unused-packages = true - - -[[constraint]] - name = "github.com/go-sql-driver/mysql" - version = "1.4.0" - -[[constraint]] - name = "github.com/kelseyhightower/envconfig" - version = "1.3.0" - -[[constraint]] - name = "github.com/naoina/toml" - version = "0.1.1" - -[[constraint]] - name = "github.com/rs/cors" - version = "1.5.0" - -[[constraint]] - name = "github.com/stretchr/testify" - version = "1.2.2" - -[prune] - go-tests = true - unused-packages = true diff --git a/config_test.go b/config_test.go index 1051617..316b4cb 100644 --- a/config_test.go +++ b/config_test.go @@ -3,9 +3,10 @@ package main import ( "testing" - "github.com/naoina/toml" "github.com/putdotio/pas/internal/event" "github.com/putdotio/pas/internal/property" + + "github.com/naoina/toml" "github.com/stretchr/testify/assert" ) diff --git a/go.mod b/go.mod new file mode 100644 index 0000000..35346ba --- /dev/null +++ b/go.mod @@ -0,0 +1,11 @@ +module github.com/putdotio/pas + +go 1.15 + +require ( + github.com/go-sql-driver/mysql v1.5.0 + github.com/kelseyhightower/envconfig v1.4.0 + github.com/naoina/go-stringutil v0.1.0 // indirect + github.com/naoina/toml v0.1.1 + github.com/rs/cors v1.7.0 +) diff --git a/go.sum b/go.sum new file mode 100644 index 0000000..2e82a80 --- /dev/null +++ b/go.sum @@ -0,0 +1,10 @@ +github.com/go-sql-driver/mysql v1.5.0 h1:ozyZYNQW3x3HtqT1jira07DN2PArx2v7/mN66gGcHOs= +github.com/go-sql-driver/mysql v1.5.0/go.mod h1:DCzpHaOWr8IXmIStZouvnhqoel9Qv2LBy8hT2VhHyBg= +github.com/kelseyhightower/envconfig v1.4.0 h1:Im6hONhd3pLkfDFsbRgu68RDNkGF1r3dvMUtDTo2cv8= +github.com/kelseyhightower/envconfig v1.4.0/go.mod h1:cccZRl6mQpaq41TPp5QxidR+Sa3axMbJDNb//FQX6Gg= +github.com/naoina/go-stringutil v0.1.0 h1:rCUeRUHjBjGTSHl0VC00jUPLz8/F9dDzYI70Hzifhks= +github.com/naoina/go-stringutil v0.1.0/go.mod h1:XJ2SJL9jCtBh+P9q5btrd/Ylo8XwT/h1USek5+NqSA0= +github.com/naoina/toml v0.1.1 h1:PT/lllxVVN0gzzSqSlHEmP8MJB4MY2U7STGxiouV4X8= +github.com/naoina/toml v0.1.1/go.mod h1:NBIhNtsFMo3G2szEBne+bO4gS192HuIYRqfvOWb4i1E= +github.com/rs/cors v1.7.0 h1:+88SsELBHx5r+hZ8TCkggzSstaWNbDvThkVK8H6f9ik= +github.com/rs/cors v1.7.0/go.mod h1:gFx+x8UowdsKA9AchylcLynDq+nNFfI8FkUZdN/jGCU= diff --git a/internal/analytics/analytics_test.go b/internal/analytics/analytics_test.go index da1f3ea..165066b 100644 --- a/internal/analytics/analytics_test.go +++ b/internal/analytics/analytics_test.go @@ -13,6 +13,7 @@ import ( "github.com/putdotio/pas/internal/event" "github.com/putdotio/pas/internal/property" "github.com/putdotio/pas/internal/user" + "github.com/stretchr/testify/assert" ) diff --git a/internal/event/event_test.go b/internal/event/event_test.go index 551fce3..a76c6df 100644 --- a/internal/event/event_test.go +++ b/internal/event/event_test.go @@ -5,6 +5,7 @@ import ( "testing" "github.com/putdotio/pas/internal/user" + "github.com/stretchr/testify/assert" ) diff --git a/internal/inserter/inserter.go b/internal/inserter/inserter.go index 1b58123..372e70a 100644 --- a/internal/inserter/inserter.go +++ b/internal/inserter/inserter.go @@ -4,8 +4,9 @@ import ( "database/sql" "time" - "github.com/go-sql-driver/mysql" "github.com/putdotio/pas/internal/property" + + "github.com/go-sql-driver/mysql" ) type Inserter interface { diff --git a/internal/property/type_test.go b/internal/property/type_test.go index 4704fb2..d8cd98f 100644 --- a/internal/property/type_test.go +++ b/internal/property/type_test.go @@ -5,6 +5,7 @@ import ( "testing" "github.com/putdotio/pas/internal/property" + "github.com/stretchr/testify/assert" )