Adjust import paths
This commit is contained in:
parent
c43e856136
commit
82bffe9144
27 changed files with 110 additions and 110 deletions
|
@ -20,7 +20,7 @@ jobs:
|
||||||
|
|
||||||
environment:
|
environment:
|
||||||
GOPATH: /go
|
GOPATH: /go
|
||||||
ROOTPATH: /go/src/github.com/vattle/sqlboiler
|
ROOTPATH: /go/src/github.com/volatiletech/sqlboiler
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
- run:
|
- run:
|
||||||
|
@ -93,10 +93,10 @@ jobs:
|
||||||
|
|
||||||
- run:
|
- run:
|
||||||
name: Make GOPATH
|
name: Make GOPATH
|
||||||
command: mkdir -p /go/src/github.com/vattle/sqlboiler
|
command: mkdir -p /go/src/github.com/volatiletech/sqlboiler
|
||||||
|
|
||||||
- checkout:
|
- checkout:
|
||||||
path: /go/src/github.com/vattle/sqlboiler
|
path: /go/src/github.com/volatiletech/sqlboiler
|
||||||
|
|
||||||
- run:
|
- run:
|
||||||
name: Create PSQL DB
|
name: Create PSQL DB
|
||||||
|
@ -118,7 +118,7 @@ jobs:
|
||||||
name: Build SQLBoiler
|
name: Build SQLBoiler
|
||||||
command: |
|
command: |
|
||||||
cd $ROOTPATH; go get -v -t
|
cd $ROOTPATH; go get -v -t
|
||||||
cd $ROOTPATH; go build -v github.com/vattle/sqlboiler
|
cd $ROOTPATH; go build -v github.com/volatiletech/sqlboiler
|
||||||
|
|
||||||
- run:
|
- run:
|
||||||
name: 'Configure SQLBoiler: PSQL'
|
name: 'Configure SQLBoiler: PSQL'
|
||||||
|
|
26
README.md
26
README.md
|
@ -1,12 +1,12 @@
|
||||||
![sqlboiler logo](http://i.imgur.com/ilkv0r9.png)
|
![sqlboiler logo](http://i.imgur.com/ilkv0r9.png)
|
||||||
|
|
||||||
[![License](https://img.shields.io/badge/license-BSD-blue.svg)](https://github.com/vattle/sqlboiler/blob/master/LICENSE)
|
[![License](https://img.shields.io/badge/license-BSD-blue.svg)](https://github.com/volatiletech/sqlboiler/blob/master/LICENSE)
|
||||||
[![GoDoc](https://godoc.org/github.com/vattle/sqlboiler?status.svg)](https://godoc.org/github.com/vattle/sqlboiler)
|
[![GoDoc](https://godoc.org/github.com/volatiletech/sqlboiler?status.svg)](https://godoc.org/github.com/volatiletech/sqlboiler)
|
||||||
[![Mail](https://img.shields.io/badge/mail%20list-sqlboiler-lightgrey.svg)](https://groups.google.com/a/volatile.tech/forum/#!forum/sqlboiler)
|
[![Mail](https://img.shields.io/badge/mail%20list-sqlboiler-lightgrey.svg)](https://groups.google.com/a/volatile.tech/forum/#!forum/sqlboiler)
|
||||||
[![Mail-Annc](https://img.shields.io/badge/mail%20list-sqlboiler--announce-lightgrey.svg)](https://groups.google.com/a/volatile.tech/forum/#!forum/sqlboiler-announce)
|
[![Mail-Annc](https://img.shields.io/badge/mail%20list-sqlboiler--announce-lightgrey.svg)](https://groups.google.com/a/volatile.tech/forum/#!forum/sqlboiler-announce)
|
||||||
[![Slack](https://img.shields.io/badge/slack-%23general-lightgrey.svg)](https://sqlboiler.from-the.cloud)
|
[![Slack](https://img.shields.io/badge/slack-%23general-lightgrey.svg)](https://sqlboiler.from-the.cloud)
|
||||||
[![CircleCI](https://circleci.com/gh/vattle/sqlboiler.svg?style=shield)](https://circleci.com/gh/vattle/sqlboiler)
|
[![CircleCI](https://circleci.com/gh/volatiletech/sqlboiler.svg?style=shield)](https://circleci.com/gh/volatiletech/sqlboiler)
|
||||||
[![Go Report Card](https://goreportcard.com/badge/vattle/sqlboiler)](http://goreportcard.com/report/vattle/sqlboiler)
|
[![Go Report Card](https://goreportcard.com/badge/volatiletech/sqlboiler)](http://goreportcard.com/report/volatiletech/sqlboiler)
|
||||||
|
|
||||||
SQLBoiler is a tool to generate a Go ORM tailored to your database schema.
|
SQLBoiler is a tool to generate a Go ORM tailored to your database schema.
|
||||||
|
|
||||||
|
@ -123,7 +123,7 @@ For a comprehensive list of available operations and examples please see [Featur
|
||||||
```go
|
```go
|
||||||
import (
|
import (
|
||||||
// Import this so we don't have to use qm.Limit etc.
|
// Import this so we don't have to use qm.Limit etc.
|
||||||
. "github.com/vattle/sqlboiler/queries/qm"
|
. "github.com/volatiletech/sqlboiler/queries/qm"
|
||||||
)
|
)
|
||||||
|
|
||||||
// Open handle to database like normal
|
// Open handle to database like normal
|
||||||
|
@ -215,7 +215,7 @@ fmt.Println(len(users.R.FavoriteMovies))
|
||||||
#### Download
|
#### Download
|
||||||
|
|
||||||
```shell
|
```shell
|
||||||
go get -u -t github.com/vattle/sqlboiler
|
go get -u -t github.com/volatiletech/sqlboiler
|
||||||
```
|
```
|
||||||
|
|
||||||
#### Configuration
|
#### Configuration
|
||||||
|
@ -296,7 +296,7 @@ generate models for, we can invoke the sqlboiler command line utility.
|
||||||
|
|
||||||
```text
|
```text
|
||||||
SQL Boiler generates a Go ORM from template files, tailored to your database schema.
|
SQL Boiler generates a Go ORM from template files, tailored to your database schema.
|
||||||
Complete documentation is available at http://github.com/vattle/sqlboiler
|
Complete documentation is available at http://github.com/volatiletech/sqlboiler
|
||||||
|
|
||||||
Usage:
|
Usage:
|
||||||
sqlboiler [flags] <driver>
|
sqlboiler [flags] <driver>
|
||||||
|
@ -626,7 +626,7 @@ when performing query building. Here is a list of all of your generated query mo
|
||||||
|
|
||||||
```go
|
```go
|
||||||
// Dot import so we can access query mods directly instead of prefixing with "qm."
|
// Dot import so we can access query mods directly instead of prefixing with "qm."
|
||||||
import . "github.com/vattle/sqlboiler/queries/qm"
|
import . "github.com/volatiletech/sqlboiler/queries/qm"
|
||||||
|
|
||||||
// Use a raw query against a generated struct (Pilot in this example)
|
// Use a raw query against a generated struct (Pilot in this example)
|
||||||
// If this query mod exists in your call, it will override the others.
|
// If this query mod exists in your call, it will override the others.
|
||||||
|
@ -737,7 +737,7 @@ in combination with your own custom, non-generated model.
|
||||||
|
|
||||||
### Binding
|
### Binding
|
||||||
|
|
||||||
For a comprehensive ruleset for `Bind()` you can refer to our [godoc](https://godoc.org/github.com/vattle/sqlboiler/queries#Bind).
|
For a comprehensive ruleset for `Bind()` you can refer to our [godoc](https://godoc.org/github.com/volatiletech/sqlboiler/queries#Bind).
|
||||||
|
|
||||||
The `Bind()` [Finisher](#finisher) allows the results of a query built with
|
The `Bind()` [Finisher](#finisher) allows the results of a query built with
|
||||||
the [Raw SQL](#raw-query) method or the [Query Builder](#query-building) methods to be bound
|
the [Raw SQL](#raw-query) method or the [Query Builder](#query-building) methods to be bound
|
||||||
|
@ -991,7 +991,7 @@ tx.Rollback()
|
||||||
```
|
```
|
||||||
|
|
||||||
It's also worth noting that there's a way to take advantage of `boil.SetDB()`
|
It's also worth noting that there's a way to take advantage of `boil.SetDB()`
|
||||||
by using the [boil.Begin()](https://godoc.org/github.com/vattle/sqlboiler/boil#Begin) function.
|
by using the [boil.Begin()](https://godoc.org/github.com/volatiletech/sqlboiler/boil#Begin) function.
|
||||||
This opens a transaction using the globally stored database.
|
This opens a transaction using the globally stored database.
|
||||||
|
|
||||||
### Debug Logging
|
### Debug Logging
|
||||||
|
@ -1298,12 +1298,12 @@ You *must* use a DSN flag in MySQL connections, see: [Requirements](#requirement
|
||||||
|
|
||||||
#### Where is the homepage?
|
#### Where is the homepage?
|
||||||
|
|
||||||
The homepage for the [SQLBoiler](https://github.com/vattle/sqlboiler) [Golang ORM](https://github.com/vattle/sqlboiler)
|
The homepage for the [SQLBoiler](https://github.com/volatiletech/sqlboiler) [Golang ORM](https://github.com/volatiletech/sqlboiler)
|
||||||
generator is located at: https://github.com/vattle/sqlboiler
|
generator is located at: https://github.com/volatiletech/sqlboiler
|
||||||
|
|
||||||
## Benchmarks
|
## Benchmarks
|
||||||
|
|
||||||
If you'd like to run the benchmarks yourself check out our [boilbench](https://github.com/vattle/boilbench) repo.
|
If you'd like to run the benchmarks yourself check out our [boilbench](https://github.com/volatiletech/boilbench) repo.
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
go test -bench . -benchmem
|
go test -bench . -benchmem
|
||||||
|
|
|
@ -3,7 +3,7 @@ package bdb
|
||||||
import (
|
import (
|
||||||
"strings"
|
"strings"
|
||||||
|
|
||||||
"github.com/vattle/sqlboiler/strmangle"
|
"github.com/volatiletech/sqlboiler/strmangle"
|
||||||
)
|
)
|
||||||
|
|
||||||
// Column holds information about a database column.
|
// Column holds information about a database column.
|
||||||
|
|
|
@ -1,8 +1,8 @@
|
||||||
package drivers
|
package drivers
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"github.com/vattle/sqlboiler/bdb"
|
"github.com/volatiletech/sqlboiler/bdb"
|
||||||
"github.com/vattle/sqlboiler/strmangle"
|
"github.com/volatiletech/sqlboiler/strmangle"
|
||||||
)
|
)
|
||||||
|
|
||||||
// MockDriver is a mock implementation of the bdb driver Interface
|
// MockDriver is a mock implementation of the bdb driver Interface
|
||||||
|
|
|
@ -8,7 +8,7 @@ import (
|
||||||
|
|
||||||
_ "github.com/denisenkom/go-mssqldb"
|
_ "github.com/denisenkom/go-mssqldb"
|
||||||
"github.com/pkg/errors"
|
"github.com/pkg/errors"
|
||||||
"github.com/vattle/sqlboiler/bdb"
|
"github.com/volatiletech/sqlboiler/bdb"
|
||||||
)
|
)
|
||||||
|
|
||||||
// MSSQLDriver holds the database connection string and a handle
|
// MSSQLDriver holds the database connection string and a handle
|
||||||
|
|
|
@ -8,7 +8,7 @@ import (
|
||||||
|
|
||||||
"github.com/go-sql-driver/mysql"
|
"github.com/go-sql-driver/mysql"
|
||||||
"github.com/pkg/errors"
|
"github.com/pkg/errors"
|
||||||
"github.com/vattle/sqlboiler/bdb"
|
"github.com/volatiletech/sqlboiler/bdb"
|
||||||
)
|
)
|
||||||
|
|
||||||
// TinyintAsBool is a global that is set from main.go if a user specifies
|
// TinyintAsBool is a global that is set from main.go if a user specifies
|
||||||
|
|
|
@ -10,8 +10,8 @@ import (
|
||||||
|
|
||||||
_ "github.com/lib/pq"
|
_ "github.com/lib/pq"
|
||||||
"github.com/pkg/errors"
|
"github.com/pkg/errors"
|
||||||
"github.com/vattle/sqlboiler/bdb"
|
"github.com/volatiletech/sqlboiler/bdb"
|
||||||
"github.com/vattle/sqlboiler/strmangle"
|
"github.com/volatiletech/sqlboiler/strmangle"
|
||||||
)
|
)
|
||||||
|
|
||||||
// PostgresDriver holds the database connection string and a handle
|
// PostgresDriver holds the database connection string and a handle
|
||||||
|
|
|
@ -3,7 +3,7 @@ package bdb
|
||||||
import (
|
import (
|
||||||
"testing"
|
"testing"
|
||||||
|
|
||||||
"github.com/vattle/sqlboiler/strmangle"
|
"github.com/volatiletech/sqlboiler/strmangle"
|
||||||
)
|
)
|
||||||
|
|
||||||
type testMockDriver struct{}
|
type testMockDriver struct{}
|
||||||
|
|
|
@ -13,10 +13,10 @@ import (
|
||||||
"text/template"
|
"text/template"
|
||||||
|
|
||||||
"github.com/pkg/errors"
|
"github.com/pkg/errors"
|
||||||
"github.com/vattle/sqlboiler/bdb"
|
"github.com/volatiletech/sqlboiler/bdb"
|
||||||
"github.com/vattle/sqlboiler/bdb/drivers"
|
"github.com/volatiletech/sqlboiler/bdb/drivers"
|
||||||
"github.com/vattle/sqlboiler/queries"
|
"github.com/volatiletech/sqlboiler/queries"
|
||||||
"github.com/vattle/sqlboiler/strmangle"
|
"github.com/volatiletech/sqlboiler/strmangle"
|
||||||
)
|
)
|
||||||
|
|
||||||
const (
|
const (
|
||||||
|
@ -267,7 +267,7 @@ func (s *State) processReplacements() error {
|
||||||
return nil
|
return nil
|
||||||
}
|
}
|
||||||
|
|
||||||
var basePackage = "github.com/vattle/sqlboiler"
|
var basePackage = "github.com/volatiletech/sqlboiler"
|
||||||
|
|
||||||
func getBasePath(baseDirConfig string) (string, error) {
|
func getBasePath(baseDirConfig string) (string, error) {
|
||||||
if len(baseDirConfig) > 0 {
|
if len(baseDirConfig) > 0 {
|
||||||
|
|
|
@ -6,7 +6,7 @@ import (
|
||||||
"sort"
|
"sort"
|
||||||
"strings"
|
"strings"
|
||||||
|
|
||||||
"github.com/vattle/sqlboiler/bdb"
|
"github.com/volatiletech/sqlboiler/bdb"
|
||||||
)
|
)
|
||||||
|
|
||||||
// imports defines the optional standard imports and
|
// imports defines the optional standard imports and
|
||||||
|
@ -171,25 +171,25 @@ func newImporter() importer {
|
||||||
},
|
},
|
||||||
thirdParty: importList{
|
thirdParty: importList{
|
||||||
`"github.com/pkg/errors"`,
|
`"github.com/pkg/errors"`,
|
||||||
`"github.com/vattle/sqlboiler/boil"`,
|
`"github.com/volatiletech/sqlboiler/boil"`,
|
||||||
`"github.com/vattle/sqlboiler/queries"`,
|
`"github.com/volatiletech/sqlboiler/queries"`,
|
||||||
`"github.com/vattle/sqlboiler/queries/qm"`,
|
`"github.com/volatiletech/sqlboiler/queries/qm"`,
|
||||||
`"github.com/vattle/sqlboiler/strmangle"`,
|
`"github.com/volatiletech/sqlboiler/strmangle"`,
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
|
|
||||||
imp.Singleton = mapImports{
|
imp.Singleton = mapImports{
|
||||||
"boil_queries": {
|
"boil_queries": {
|
||||||
thirdParty: importList{
|
thirdParty: importList{
|
||||||
`"github.com/vattle/sqlboiler/boil"`,
|
`"github.com/volatiletech/sqlboiler/boil"`,
|
||||||
`"github.com/vattle/sqlboiler/queries"`,
|
`"github.com/volatiletech/sqlboiler/queries"`,
|
||||||
`"github.com/vattle/sqlboiler/queries/qm"`,
|
`"github.com/volatiletech/sqlboiler/queries/qm"`,
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
"boil_types": {
|
"boil_types": {
|
||||||
thirdParty: importList{
|
thirdParty: importList{
|
||||||
`"github.com/pkg/errors"`,
|
`"github.com/pkg/errors"`,
|
||||||
`"github.com/vattle/sqlboiler/strmangle"`,
|
`"github.com/volatiletech/sqlboiler/strmangle"`,
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
|
@ -201,9 +201,9 @@ func newImporter() importer {
|
||||||
`"testing"`,
|
`"testing"`,
|
||||||
},
|
},
|
||||||
thirdParty: importList{
|
thirdParty: importList{
|
||||||
`"github.com/vattle/sqlboiler/boil"`,
|
`"github.com/volatiletech/sqlboiler/boil"`,
|
||||||
`"github.com/vattle/sqlboiler/randomize"`,
|
`"github.com/volatiletech/sqlboiler/randomize"`,
|
||||||
`"github.com/vattle/sqlboiler/strmangle"`,
|
`"github.com/volatiletech/sqlboiler/strmangle"`,
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -223,7 +223,7 @@ func newImporter() importer {
|
||||||
`"github.com/kat-co/vala"`,
|
`"github.com/kat-co/vala"`,
|
||||||
`"github.com/pkg/errors"`,
|
`"github.com/pkg/errors"`,
|
||||||
`"github.com/spf13/viper"`,
|
`"github.com/spf13/viper"`,
|
||||||
`"github.com/vattle/sqlboiler/boil"`,
|
`"github.com/volatiletech/sqlboiler/boil"`,
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
"boil_queries_test": {
|
"boil_queries_test": {
|
||||||
|
@ -236,7 +236,7 @@ func newImporter() importer {
|
||||||
`"regexp"`,
|
`"regexp"`,
|
||||||
},
|
},
|
||||||
thirdParty: importList{
|
thirdParty: importList{
|
||||||
`"github.com/vattle/sqlboiler/boil"`,
|
`"github.com/volatiletech/sqlboiler/boil"`,
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
"boil_suites_test": {
|
"boil_suites_test": {
|
||||||
|
@ -261,8 +261,8 @@ func newImporter() importer {
|
||||||
thirdParty: importList{
|
thirdParty: importList{
|
||||||
`"github.com/pkg/errors"`,
|
`"github.com/pkg/errors"`,
|
||||||
`"github.com/spf13/viper"`,
|
`"github.com/spf13/viper"`,
|
||||||
`"github.com/vattle/sqlboiler/bdb/drivers"`,
|
`"github.com/volatiletech/sqlboiler/bdb/drivers"`,
|
||||||
`"github.com/vattle/sqlboiler/randomize"`,
|
`"github.com/volatiletech/sqlboiler/randomize"`,
|
||||||
`_ "github.com/lib/pq"`,
|
`_ "github.com/lib/pq"`,
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
@ -280,8 +280,8 @@ func newImporter() importer {
|
||||||
thirdParty: importList{
|
thirdParty: importList{
|
||||||
`"github.com/pkg/errors"`,
|
`"github.com/pkg/errors"`,
|
||||||
`"github.com/spf13/viper"`,
|
`"github.com/spf13/viper"`,
|
||||||
`"github.com/vattle/sqlboiler/bdb/drivers"`,
|
`"github.com/volatiletech/sqlboiler/bdb/drivers"`,
|
||||||
`"github.com/vattle/sqlboiler/randomize"`,
|
`"github.com/volatiletech/sqlboiler/randomize"`,
|
||||||
`_ "github.com/go-sql-driver/mysql"`,
|
`_ "github.com/go-sql-driver/mysql"`,
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
@ -297,8 +297,8 @@ func newImporter() importer {
|
||||||
thirdParty: importList{
|
thirdParty: importList{
|
||||||
`"github.com/pkg/errors"`,
|
`"github.com/pkg/errors"`,
|
||||||
`"github.com/spf13/viper"`,
|
`"github.com/spf13/viper"`,
|
||||||
`"github.com/vattle/sqlboiler/bdb/drivers"`,
|
`"github.com/volatiletech/sqlboiler/bdb/drivers"`,
|
||||||
`"github.com/vattle/sqlboiler/randomize"`,
|
`"github.com/volatiletech/sqlboiler/randomize"`,
|
||||||
`_ "github.com/denisenkom/go-mssqldb"`,
|
`_ "github.com/denisenkom/go-mssqldb"`,
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
@ -309,79 +309,79 @@ func newImporter() importer {
|
||||||
// TranslateColumnType to see the type assignments.
|
// TranslateColumnType to see the type assignments.
|
||||||
imp.BasedOnType = mapImports{
|
imp.BasedOnType = mapImports{
|
||||||
"null.Float32": {
|
"null.Float32": {
|
||||||
thirdParty: importList{`"gopkg.in/nullbio/null.v6"`},
|
thirdParty: importList{`"gopkg.in/volatiletech/null.v6"`},
|
||||||
},
|
},
|
||||||
"null.Float64": {
|
"null.Float64": {
|
||||||
thirdParty: importList{`"gopkg.in/nullbio/null.v6"`},
|
thirdParty: importList{`"gopkg.in/volatiletech/null.v6"`},
|
||||||
},
|
},
|
||||||
"null.Int": {
|
"null.Int": {
|
||||||
thirdParty: importList{`"gopkg.in/nullbio/null.v6"`},
|
thirdParty: importList{`"gopkg.in/volatiletech/null.v6"`},
|
||||||
},
|
},
|
||||||
"null.Int8": {
|
"null.Int8": {
|
||||||
thirdParty: importList{`"gopkg.in/nullbio/null.v6"`},
|
thirdParty: importList{`"gopkg.in/volatiletech/null.v6"`},
|
||||||
},
|
},
|
||||||
"null.Int16": {
|
"null.Int16": {
|
||||||
thirdParty: importList{`"gopkg.in/nullbio/null.v6"`},
|
thirdParty: importList{`"gopkg.in/volatiletech/null.v6"`},
|
||||||
},
|
},
|
||||||
"null.Int32": {
|
"null.Int32": {
|
||||||
thirdParty: importList{`"gopkg.in/nullbio/null.v6"`},
|
thirdParty: importList{`"gopkg.in/volatiletech/null.v6"`},
|
||||||
},
|
},
|
||||||
"null.Int64": {
|
"null.Int64": {
|
||||||
thirdParty: importList{`"gopkg.in/nullbio/null.v6"`},
|
thirdParty: importList{`"gopkg.in/volatiletech/null.v6"`},
|
||||||
},
|
},
|
||||||
"null.Uint": {
|
"null.Uint": {
|
||||||
thirdParty: importList{`"gopkg.in/nullbio/null.v6"`},
|
thirdParty: importList{`"gopkg.in/volatiletech/null.v6"`},
|
||||||
},
|
},
|
||||||
"null.Uint8": {
|
"null.Uint8": {
|
||||||
thirdParty: importList{`"gopkg.in/nullbio/null.v6"`},
|
thirdParty: importList{`"gopkg.in/volatiletech/null.v6"`},
|
||||||
},
|
},
|
||||||
"null.Uint16": {
|
"null.Uint16": {
|
||||||
thirdParty: importList{`"gopkg.in/nullbio/null.v6"`},
|
thirdParty: importList{`"gopkg.in/volatiletech/null.v6"`},
|
||||||
},
|
},
|
||||||
"null.Uint32": {
|
"null.Uint32": {
|
||||||
thirdParty: importList{`"gopkg.in/nullbio/null.v6"`},
|
thirdParty: importList{`"gopkg.in/volatiletech/null.v6"`},
|
||||||
},
|
},
|
||||||
"null.Uint64": {
|
"null.Uint64": {
|
||||||
thirdParty: importList{`"gopkg.in/nullbio/null.v6"`},
|
thirdParty: importList{`"gopkg.in/volatiletech/null.v6"`},
|
||||||
},
|
},
|
||||||
"null.String": {
|
"null.String": {
|
||||||
thirdParty: importList{`"gopkg.in/nullbio/null.v6"`},
|
thirdParty: importList{`"gopkg.in/volatiletech/null.v6"`},
|
||||||
},
|
},
|
||||||
"null.Bool": {
|
"null.Bool": {
|
||||||
thirdParty: importList{`"gopkg.in/nullbio/null.v6"`},
|
thirdParty: importList{`"gopkg.in/volatiletech/null.v6"`},
|
||||||
},
|
},
|
||||||
"null.Time": {
|
"null.Time": {
|
||||||
thirdParty: importList{`"gopkg.in/nullbio/null.v6"`},
|
thirdParty: importList{`"gopkg.in/volatiletech/null.v6"`},
|
||||||
},
|
},
|
||||||
"null.JSON": {
|
"null.JSON": {
|
||||||
thirdParty: importList{`"gopkg.in/nullbio/null.v6"`},
|
thirdParty: importList{`"gopkg.in/volatiletech/null.v6"`},
|
||||||
},
|
},
|
||||||
"null.Bytes": {
|
"null.Bytes": {
|
||||||
thirdParty: importList{`"gopkg.in/nullbio/null.v6"`},
|
thirdParty: importList{`"gopkg.in/volatiletech/null.v6"`},
|
||||||
},
|
},
|
||||||
"time.Time": {
|
"time.Time": {
|
||||||
standard: importList{`"time"`},
|
standard: importList{`"time"`},
|
||||||
},
|
},
|
||||||
"types.JSON": {
|
"types.JSON": {
|
||||||
thirdParty: importList{`"github.com/vattle/sqlboiler/types"`},
|
thirdParty: importList{`"github.com/volatiletech/sqlboiler/types"`},
|
||||||
},
|
},
|
||||||
"types.BytesArray": {
|
"types.BytesArray": {
|
||||||
thirdParty: importList{`"github.com/vattle/sqlboiler/types"`},
|
thirdParty: importList{`"github.com/volatiletech/sqlboiler/types"`},
|
||||||
},
|
},
|
||||||
"types.Int64Array": {
|
"types.Int64Array": {
|
||||||
thirdParty: importList{`"github.com/vattle/sqlboiler/types"`},
|
thirdParty: importList{`"github.com/volatiletech/sqlboiler/types"`},
|
||||||
},
|
},
|
||||||
"types.Float64Array": {
|
"types.Float64Array": {
|
||||||
thirdParty: importList{`"github.com/vattle/sqlboiler/types"`},
|
thirdParty: importList{`"github.com/volatiletech/sqlboiler/types"`},
|
||||||
},
|
},
|
||||||
"types.BoolArray": {
|
"types.BoolArray": {
|
||||||
thirdParty: importList{`"github.com/vattle/sqlboiler/types"`},
|
thirdParty: importList{`"github.com/volatiletech/sqlboiler/types"`},
|
||||||
},
|
},
|
||||||
"types.StringArray": {
|
"types.StringArray": {
|
||||||
thirdParty: importList{`"github.com/vattle/sqlboiler/types"`},
|
thirdParty: importList{`"github.com/volatiletech/sqlboiler/types"`},
|
||||||
},
|
},
|
||||||
"types.Hstore": {
|
"types.Hstore": {
|
||||||
thirdParty: importList{`"github.com/vattle/sqlboiler/types"`},
|
thirdParty: importList{`"github.com/volatiletech/sqlboiler/types"`},
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -6,7 +6,7 @@ import (
|
||||||
"testing"
|
"testing"
|
||||||
|
|
||||||
"github.com/pkg/errors"
|
"github.com/pkg/errors"
|
||||||
"github.com/vattle/sqlboiler/bdb"
|
"github.com/volatiletech/sqlboiler/bdb"
|
||||||
)
|
)
|
||||||
|
|
||||||
func TestImportsSort(t *testing.T) {
|
func TestImportsSort(t *testing.T) {
|
||||||
|
@ -234,7 +234,7 @@ func TestCombineTypeImports(t *testing.T) {
|
||||||
`"fmt"`,
|
`"fmt"`,
|
||||||
},
|
},
|
||||||
thirdParty: importList{
|
thirdParty: importList{
|
||||||
`"github.com/vattle/sqlboiler/boil"`,
|
`"github.com/volatiletech/sqlboiler/boil"`,
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -245,8 +245,8 @@ func TestCombineTypeImports(t *testing.T) {
|
||||||
`"time"`,
|
`"time"`,
|
||||||
},
|
},
|
||||||
thirdParty: importList{
|
thirdParty: importList{
|
||||||
`"github.com/vattle/sqlboiler/boil"`,
|
`"github.com/volatiletech/sqlboiler/boil"`,
|
||||||
`"gopkg.in/nullbio/null.v6"`,
|
`"gopkg.in/volatiletech/null.v6"`,
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -280,8 +280,8 @@ func TestCombineTypeImports(t *testing.T) {
|
||||||
`"time"`,
|
`"time"`,
|
||||||
},
|
},
|
||||||
thirdParty: importList{
|
thirdParty: importList{
|
||||||
`"github.com/vattle/sqlboiler/boil"`,
|
`"github.com/volatiletech/sqlboiler/boil"`,
|
||||||
`"gopkg.in/nullbio/null.v6"`,
|
`"gopkg.in/volatiletech/null.v6"`,
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -297,11 +297,11 @@ func TestCombineImports(t *testing.T) {
|
||||||
|
|
||||||
a := imports{
|
a := imports{
|
||||||
standard: importList{"fmt"},
|
standard: importList{"fmt"},
|
||||||
thirdParty: importList{"github.com/vattle/sqlboiler", "gopkg.in/nullbio/null.v6"},
|
thirdParty: importList{"github.com/volatiletech/sqlboiler", "gopkg.in/volatiletech/null.v6"},
|
||||||
}
|
}
|
||||||
b := imports{
|
b := imports{
|
||||||
standard: importList{"os"},
|
standard: importList{"os"},
|
||||||
thirdParty: importList{"github.com/vattle/sqlboiler"},
|
thirdParty: importList{"github.com/volatiletech/sqlboiler"},
|
||||||
}
|
}
|
||||||
|
|
||||||
c := combineImports(a, b)
|
c := combineImports(a, b)
|
||||||
|
@ -309,8 +309,8 @@ func TestCombineImports(t *testing.T) {
|
||||||
if c.standard[0] != "fmt" && c.standard[1] != "os" {
|
if c.standard[0] != "fmt" && c.standard[1] != "os" {
|
||||||
t.Errorf("Wanted: fmt, os got: %#v", c.standard)
|
t.Errorf("Wanted: fmt, os got: %#v", c.standard)
|
||||||
}
|
}
|
||||||
if c.thirdParty[0] != "github.com/vattle/sqlboiler" && c.thirdParty[1] != "gopkg.in/nullbio/null.v6" {
|
if c.thirdParty[0] != "github.com/volatiletech/sqlboiler" && c.thirdParty[1] != "gopkg.in/volatiletech/null.v6" {
|
||||||
t.Errorf("Wanted: github.com/vattle/sqlboiler, gopkg.in/nullbio/null.v6 got: %#v", c.thirdParty)
|
t.Errorf("Wanted: github.com/volatiletech/sqlboiler, gopkg.in/volatiletech/null.v6 got: %#v", c.thirdParty)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -14,7 +14,7 @@ import (
|
||||||
"github.com/pkg/errors"
|
"github.com/pkg/errors"
|
||||||
)
|
)
|
||||||
|
|
||||||
var noEditDisclaimer = []byte(`// This file is generated by SQLBoiler (https://github.com/vattle/sqlboiler)
|
var noEditDisclaimer = []byte(`// This file is generated by SQLBoiler (https://github.com/volatiletech/sqlboiler)
|
||||||
// and is meant to be re-generated in place and/or deleted at any time.
|
// and is meant to be re-generated in place and/or deleted at any time.
|
||||||
// DO NOT EDIT
|
// DO NOT EDIT
|
||||||
|
|
||||||
|
|
|
@ -9,9 +9,9 @@ import (
|
||||||
"text/template"
|
"text/template"
|
||||||
|
|
||||||
"github.com/pkg/errors"
|
"github.com/pkg/errors"
|
||||||
"github.com/vattle/sqlboiler/bdb"
|
"github.com/volatiletech/sqlboiler/bdb"
|
||||||
"github.com/vattle/sqlboiler/queries"
|
"github.com/volatiletech/sqlboiler/queries"
|
||||||
"github.com/vattle/sqlboiler/strmangle"
|
"github.com/volatiletech/sqlboiler/strmangle"
|
||||||
)
|
)
|
||||||
|
|
||||||
// templateData for sqlboiler templates
|
// templateData for sqlboiler templates
|
||||||
|
|
|
@ -4,8 +4,8 @@ import (
|
||||||
"fmt"
|
"fmt"
|
||||||
"strings"
|
"strings"
|
||||||
|
|
||||||
"github.com/vattle/sqlboiler/bdb"
|
"github.com/volatiletech/sqlboiler/bdb"
|
||||||
"github.com/vattle/sqlboiler/strmangle"
|
"github.com/volatiletech/sqlboiler/strmangle"
|
||||||
)
|
)
|
||||||
|
|
||||||
// TxtToOne contains text that will be used by templates for a one-to-many or
|
// TxtToOne contains text that will be used by templates for a one-to-many or
|
||||||
|
|
|
@ -5,8 +5,8 @@ import (
|
||||||
"testing"
|
"testing"
|
||||||
|
|
||||||
"github.com/davecgh/go-spew/spew"
|
"github.com/davecgh/go-spew/spew"
|
||||||
"github.com/vattle/sqlboiler/bdb"
|
"github.com/volatiletech/sqlboiler/bdb"
|
||||||
"github.com/vattle/sqlboiler/bdb/drivers"
|
"github.com/volatiletech/sqlboiler/bdb/drivers"
|
||||||
)
|
)
|
||||||
|
|
||||||
func TestTxtsFromOne(t *testing.T) {
|
func TestTxtsFromOne(t *testing.T) {
|
||||||
|
|
6
main.go
6
main.go
|
@ -10,8 +10,8 @@ import (
|
||||||
"github.com/kat-co/vala"
|
"github.com/kat-co/vala"
|
||||||
"github.com/spf13/cobra"
|
"github.com/spf13/cobra"
|
||||||
"github.com/spf13/viper"
|
"github.com/spf13/viper"
|
||||||
"github.com/vattle/sqlboiler/bdb/drivers"
|
"github.com/volatiletech/sqlboiler/bdb/drivers"
|
||||||
"github.com/vattle/sqlboiler/boilingcore"
|
"github.com/volatiletech/sqlboiler/boilingcore"
|
||||||
)
|
)
|
||||||
|
|
||||||
const sqlBoilerVersion = "2.5.0"
|
const sqlBoilerVersion = "2.5.0"
|
||||||
|
@ -62,7 +62,7 @@ func main() {
|
||||||
Use: "sqlboiler [flags] <driver>",
|
Use: "sqlboiler [flags] <driver>",
|
||||||
Short: "SQL Boiler generates an ORM tailored to your database schema.",
|
Short: "SQL Boiler generates an ORM tailored to your database schema.",
|
||||||
Long: "SQL Boiler generates a Go ORM from template files, tailored to your database schema.\n" +
|
Long: "SQL Boiler generates a Go ORM from template files, tailored to your database schema.\n" +
|
||||||
`Complete documentation is available at http://github.com/vattle/sqlboiler`,
|
`Complete documentation is available at http://github.com/volatiletech/sqlboiler`,
|
||||||
Example: `sqlboiler postgres`,
|
Example: `sqlboiler postgres`,
|
||||||
PreRunE: preRun,
|
PreRunE: preRun,
|
||||||
RunE: run,
|
RunE: run,
|
||||||
|
|
|
@ -6,8 +6,8 @@ import (
|
||||||
"strings"
|
"strings"
|
||||||
|
|
||||||
"github.com/pkg/errors"
|
"github.com/pkg/errors"
|
||||||
"github.com/vattle/sqlboiler/boil"
|
"github.com/volatiletech/sqlboiler/boil"
|
||||||
"github.com/vattle/sqlboiler/strmangle"
|
"github.com/volatiletech/sqlboiler/strmangle"
|
||||||
)
|
)
|
||||||
|
|
||||||
type loadRelationshipState struct {
|
type loadRelationshipState struct {
|
||||||
|
|
|
@ -4,7 +4,7 @@ import (
|
||||||
"fmt"
|
"fmt"
|
||||||
"testing"
|
"testing"
|
||||||
|
|
||||||
"github.com/vattle/sqlboiler/boil"
|
"github.com/volatiletech/sqlboiler/boil"
|
||||||
)
|
)
|
||||||
|
|
||||||
var testEagerCounters struct {
|
var testEagerCounters struct {
|
||||||
|
|
|
@ -4,7 +4,7 @@ import (
|
||||||
"fmt"
|
"fmt"
|
||||||
"reflect"
|
"reflect"
|
||||||
|
|
||||||
"github.com/vattle/sqlboiler/strmangle"
|
"github.com/volatiletech/sqlboiler/strmangle"
|
||||||
)
|
)
|
||||||
|
|
||||||
// NonZeroDefaultSet returns the fields included in the
|
// NonZeroDefaultSet returns the fields included in the
|
||||||
|
|
|
@ -5,7 +5,7 @@ import (
|
||||||
"testing"
|
"testing"
|
||||||
"time"
|
"time"
|
||||||
|
|
||||||
null "gopkg.in/nullbio/null.v6"
|
null "gopkg.in/volatiletech/null.v6"
|
||||||
)
|
)
|
||||||
|
|
||||||
type testObj struct {
|
type testObj struct {
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
package qm
|
package qm
|
||||||
|
|
||||||
import "github.com/vattle/sqlboiler/queries"
|
import "github.com/volatiletech/sqlboiler/queries"
|
||||||
|
|
||||||
// QueryMod to modify the query object
|
// QueryMod to modify the query object
|
||||||
type QueryMod func(q *queries.Query)
|
type QueryMod func(q *queries.Query)
|
||||||
|
|
|
@ -4,7 +4,7 @@ import (
|
||||||
"database/sql"
|
"database/sql"
|
||||||
"fmt"
|
"fmt"
|
||||||
|
|
||||||
"github.com/vattle/sqlboiler/boil"
|
"github.com/volatiletech/sqlboiler/boil"
|
||||||
)
|
)
|
||||||
|
|
||||||
// joinKind is the type of join
|
// joinKind is the type of join
|
||||||
|
|
|
@ -7,7 +7,7 @@ import (
|
||||||
"sort"
|
"sort"
|
||||||
"strings"
|
"strings"
|
||||||
|
|
||||||
"github.com/vattle/sqlboiler/strmangle"
|
"github.com/volatiletech/sqlboiler/strmangle"
|
||||||
)
|
)
|
||||||
|
|
||||||
var (
|
var (
|
||||||
|
|
|
@ -8,8 +8,8 @@ import (
|
||||||
"sync"
|
"sync"
|
||||||
|
|
||||||
"github.com/pkg/errors"
|
"github.com/pkg/errors"
|
||||||
"github.com/vattle/sqlboiler/boil"
|
"github.com/volatiletech/sqlboiler/boil"
|
||||||
"github.com/vattle/sqlboiler/strmangle"
|
"github.com/volatiletech/sqlboiler/strmangle"
|
||||||
)
|
)
|
||||||
|
|
||||||
var (
|
var (
|
||||||
|
|
|
@ -14,12 +14,12 @@ import (
|
||||||
"sync/atomic"
|
"sync/atomic"
|
||||||
"time"
|
"time"
|
||||||
|
|
||||||
null "gopkg.in/nullbio/null.v6"
|
null "gopkg.in/volatiletech/null.v6"
|
||||||
|
|
||||||
"github.com/pkg/errors"
|
"github.com/pkg/errors"
|
||||||
"github.com/satori/go.uuid"
|
"github.com/satori/go.uuid"
|
||||||
"github.com/vattle/sqlboiler/strmangle"
|
"github.com/volatiletech/sqlboiler/strmangle"
|
||||||
"github.com/vattle/sqlboiler/types"
|
"github.com/volatiletech/sqlboiler/types"
|
||||||
)
|
)
|
||||||
|
|
||||||
var (
|
var (
|
||||||
|
|
|
@ -5,7 +5,7 @@ import (
|
||||||
"testing"
|
"testing"
|
||||||
"time"
|
"time"
|
||||||
|
|
||||||
null "gopkg.in/nullbio/null.v6"
|
null "gopkg.in/volatiletech/null.v6"
|
||||||
)
|
)
|
||||||
|
|
||||||
func TestRandomizeStruct(t *testing.T) {
|
func TestRandomizeStruct(t *testing.T) {
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
package strmangle
|
package strmangle
|
||||||
|
|
||||||
import "github.com/nullbio/inflect"
|
import "github.com/volatiletech/inflect"
|
||||||
|
|
||||||
var boilRuleset *inflect.Ruleset
|
var boilRuleset *inflect.Ruleset
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue