Back to

Package migrations

Latest Go to latest
Published: Jul 27, 2020 | License: MIT | Module:


Package Files

func GORMMigrate

func GORMMigrate(db *gorm.DB) error

GORMMigrate calls through to gorm's native migrate function with minimal extra logic Useful if the migrations table doesn't exist yet but we don't care

func Migrate

func Migrate(db *gorm.DB) error

Migrate iterates through available migrations, running and tracking migrations that have not been run.

func MigrateTo

func MigrateTo(db *gorm.DB, migrationID string) error

MigrateTo runs all migrations up to and including the specified migration ID

Documentation was rendered with GOOS=linux and GOARCH=amd64.

Jump to identifier

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to identifier