clair: Index | Files

package migrations

import ""

Package migrations regroups every migrations available to the pgsql database backend.


Package Files

00001_initial_schema.go migrations.go util.go


var Migrations []migrate.Migration

Migrations contains every available migrations.

func NewSimpleMigration Uses

func NewSimpleMigration(id int, qs []MigrationQuery) migrate.Migration

NewSimpleMigration returns a simple migration plan with all provided migration queries concatted in order.

func RegisterMigration Uses

func RegisterMigration(migration migrate.Migration)

RegisterMigration adds the specified migration to the available migrations.

type MigrationQuery Uses

type MigrationQuery struct {
    Up   []string
    Down []string

MigrationQuery contains the Up migration and Down migration in Plain strings.

func ConcatMigrationQueries Uses

func ConcatMigrationQueries(qs []MigrationQuery) MigrationQuery

ConcatMigrationQueries concats migration queries in the give order.

Package migrations imports 1 packages (graph) and is imported by 15 packages. Updated 2019-04-22. Refresh now. Tools for package owners.