cmd

package
v2.38.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 2, 2024 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func DownCmd

func DownCmd(m *migrate.Migrate, limit int64) error

func GotoCmd

func GotoCmd(m *migrate.Migrate, v uint64, direction string) error

func GotoVersionCmd

func GotoVersionCmd(m *migrate.Migrate, gotoVersion int64) error

func SquashCmd

func SquashCmd(m *migrate.Migrate, from uint64, to int64, version int64, name, directory string) (versions []int64, err error)

func UpCmd

func UpCmd(m *migrate.Migrate, limit int64) error

Types

type CreateOptions

type CreateOptions struct {
	Version   string
	Directory string
	Name      string
	SQLUp     []byte
	SQLDown   []byte
}

func New

func New(version int64, name, directory string) *CreateOptions

func (*CreateOptions) Create

func (c *CreateOptions) Create() error

func (*CreateOptions) Delete

func (c *CreateOptions) Delete() error

func (*CreateOptions) MoveToDir

func (c *CreateOptions) MoveToDir(destDir string) error

func (*CreateOptions) SetSQLDown

func (c *CreateOptions) SetSQLDown(data string) error

func (*CreateOptions) SetSQLUp

func (c *CreateOptions) SetSQLUp(data string) error

func (*CreateOptions) SetSQLUpFromFile

func (c *CreateOptions) SetSQLUpFromFile(filePath string) error

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL