Skip to content

Commit

Permalink
Upgrade to pop/v5 (#273)
Browse files Browse the repository at this point in the history
* update github.com/gobuffalo/pop/v5
* Fix status call
  • Loading branch information
Kelsey authored Dec 15, 2020
1 parent a2b4dd6 commit f023c23
Show file tree
Hide file tree
Showing 10 changed files with 192 additions and 164 deletions.
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ build: ## Build the binary.
go build -ldflags "-X github.com/netlify/gotrue/cmd.Version=`git rev-parse HEAD`"

deps: ## Install dependencies.
@go get -u github.com/gobuffalo/pop/soda
@go get -u github.com/gobuffalo/pop/v5/soda
@go get -u golang.org/x/lint/golint
@go mod download

Expand Down
7 changes: 4 additions & 3 deletions cmd/migrate_cmd.go
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,9 @@ package cmd

import (
"net/url"
"os"

"github.com/gobuffalo/pop"
"github.com/gobuffalo/pop/v5"
"github.com/netlify/gotrue/conf"
"github.com/pkg/errors"
"github.com/sirupsen/logrus"
Expand Down Expand Up @@ -56,7 +57,7 @@ func migrate(cmd *cobra.Command, args []string) {
logrus.Fatalf("%+v", errors.Wrap(err, "creating db migrator"))
}
logrus.Infof("before status")
err = mig.Status()
err = mig.Status(os.Stdout)
if err != nil {
logrus.Fatalf("%+v", errors.Wrap(err, "migration status"))
}
Expand All @@ -69,7 +70,7 @@ func migrate(cmd *cobra.Command, args []string) {
}

logrus.Infof("after status")
err = mig.Status()
err = mig.Status(os.Stdout)
if err != nil {
logrus.Fatalf("%+v", errors.Wrap(err, "migration status"))
}
Expand Down
28 changes: 6 additions & 22 deletions go.mod
Original file line number Diff line number Diff line change
@@ -1,55 +1,39 @@
module github.com/netlify/gotrue

require (
cloud.google.com/go v0.0.0-20170822200954-98f5696b1026 // indirect
github.com/GoogleCloudPlatform/cloudsql-proxy v0.0.0-20170623214735-571947b0f240
github.com/badoux/checkmail v0.0.0-20170203135005-d0a759655d62
github.com/beevik/etree v1.1.0
github.com/cockroachdb/cockroach-go v0.0.0-20190925194419-606b3d062051 // indirect
github.com/dgrijalva/jwt-go v3.2.0+incompatible
github.com/didip/tollbooth/v5 v5.1.1
github.com/fatih/color v1.7.0 // indirect
github.com/go-chi/chi v4.0.2+incompatible
github.com/go-sql-driver/mysql v1.4.1
github.com/gobuffalo/fizz v1.9.5 // indirect
github.com/gobuffalo/genny v0.4.1 // indirect
github.com/gobuffalo/nulls v0.1.0 // indirect
github.com/gobuffalo/packr/v2 v2.7.1 // indirect
github.com/gobuffalo/pop v4.12.2+incompatible
github.com/gobuffalo/tags v2.1.6+incompatible // indirect
github.com/go-sql-driver/mysql v1.5.0
github.com/gobuffalo/pop/v5 v5.3.1
github.com/gobuffalo/uuid v2.0.5+incompatible
github.com/imdario/mergo v0.0.0-20160216103600-3e95a51e0639
github.com/jackc/pgconn v1.1.0 // indirect
github.com/joho/godotenv v1.3.0
github.com/kelseyhightower/envconfig v1.4.0
github.com/mattn/go-colorable v0.1.4 // indirect
github.com/mattn/go-isatty v0.0.10 // indirect
github.com/mattn/go-sqlite3 v1.11.0 // indirect
github.com/netlify/mailme v1.1.1
github.com/opentracing/opentracing-go v1.1.0
github.com/patrickmn/go-cache v2.1.0+incompatible // indirect
github.com/pkg/errors v0.8.1
github.com/rogpeppe/go-internal v1.5.0 // indirect
github.com/pkg/errors v0.9.1
github.com/rs/cors v1.6.0
github.com/russellhaering/gosaml2 v0.6.0
github.com/russellhaering/goxmldsig v1.1.0
github.com/sebest/xff v0.0.0-20160910043805-6c115e0ffa35
github.com/sirupsen/logrus v1.4.2
github.com/spf13/cobra v0.0.5
github.com/spf13/cobra v0.0.6
github.com/spf13/pflag v1.0.5 // indirect
github.com/stretchr/testify v1.6.1
golang.org/x/crypto v0.0.0-20191107222254-f4817d981bb6
golang.org/x/net v0.0.0-20191108063844-7e6e90b9ea88 // indirect
golang.org/x/oauth2 v0.0.0-20170807180024-9a379c6b3e95
golang.org/x/crypto v0.0.0-20200323165209-0ec3e9974c59
golang.org/x/oauth2 v0.0.0-20180821212333-d2e6202438be
golang.org/x/sys v0.0.0-20191105231009-c1f44814a5cd // indirect
golang.org/x/time v0.0.0-20200416051211-89c76fbcd5d1 // indirect
golang.org/x/xerrors v0.0.0-20191011141410-1b5146add898 // indirect
google.golang.org/api v0.0.0-20170821230356-dd6bdadc5852 // indirect
google.golang.org/appengine v1.6.5 // indirect
gopkg.in/DataDog/dd-trace-go.v1 v1.12.1
gopkg.in/gomail.v2 v2.0.0-20160411212932-81ebce5c23df // indirect
gopkg.in/yaml.v1 v1.0.0-20140924161607-9f9df34309c0 // indirect
gopkg.in/yaml.v2 v2.2.5 // indirect
)

go 1.13
302 changes: 172 additions & 130 deletions go.sum

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion models/connection.go
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package models

import (
"github.com/gobuffalo/pop"
"github.com/gobuffalo/pop/v5"
"github.com/netlify/gotrue/storage"
)

Expand Down
2 changes: 1 addition & 1 deletion models/db_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ package models_test
import (
"testing"

"github.com/gobuffalo/pop"
"github.com/gobuffalo/pop/v5"
"github.com/netlify/gotrue/models"
"github.com/stretchr/testify/assert"
)
Expand Down
2 changes: 1 addition & 1 deletion models/instance.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import (
"database/sql"
"time"

"github.com/gobuffalo/pop"
"github.com/gobuffalo/pop/v5"
"github.com/gobuffalo/uuid"
"github.com/netlify/gotrue/conf"
"github.com/netlify/gotrue/storage"
Expand Down
5 changes: 3 additions & 2 deletions models/refresh_token.go
Original file line number Diff line number Diff line change
@@ -1,10 +1,11 @@
package models

import (
"github.com/netlify/gotrue/storage/namespace"
"time"

"github.com/gobuffalo/pop"
"github.com/netlify/gotrue/storage/namespace"

"github.com/gobuffalo/pop/v5"
"github.com/gobuffalo/uuid"
"github.com/netlify/gotrue/crypto"
"github.com/netlify/gotrue/storage"
Expand Down
2 changes: 1 addition & 1 deletion models/user.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import (
"strings"
"time"

"github.com/gobuffalo/pop"
"github.com/gobuffalo/pop/v5"
"github.com/gobuffalo/uuid"
"github.com/netlify/gotrue/storage"
"github.com/netlify/gotrue/storage/namespace"
Expand Down
4 changes: 2 additions & 2 deletions storage/dial.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@ import (

_ "github.com/GoogleCloudPlatform/cloudsql-proxy/proxy/dialers/mysql"
_ "github.com/go-sql-driver/mysql"
"github.com/gobuffalo/pop"
"github.com/gobuffalo/pop/columns"
"github.com/gobuffalo/pop/v5"
"github.com/gobuffalo/pop/v5/columns"
"github.com/netlify/gotrue/conf"
"github.com/netlify/gotrue/storage/namespace"
"github.com/pkg/errors"
Expand Down

0 comments on commit f023c23

Please sign in to comment.