vendor dependencies with dep

This commit is contained in:
dhax 2017-09-25 20:20:52 +02:00
parent 93d8310491
commit 1384296a47
2712 changed files with 965742 additions and 0 deletions

View file

@ -0,0 +1,19 @@
package main
import (
"fmt"
"github.com/go-pg/migrations"
)
func init() {
migrations.Register(func(db migrations.DB) error {
fmt.Println("seeding my_table...")
_, err := db.Exec(`INSERT INTO my_table VALUES (1)`)
return err
}, func(db migrations.DB) error {
fmt.Println("truncating my_table...")
_, err := db.Exec(`TRUNCATE my_table`)
return err
})
}