cmd

package
v1.1.0 Latest Latest
Warning

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

Go to latest
Published: Jul 7, 2026 License: GPL-2.0, GPL-3.0 Imports: 14 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func HandleCreate

func HandleCreate(dbName string)

HandleCreate creates a new pair of up/down migration files. dbName selects which configured database's migration directory to use; when empty and multiple databases are configured, the user is prompted to pick one.

func HandleDown

func HandleDown(cliURL string, dbName string, steps int)

HandleDown rolls back migrations. With multiple databases configured, dbName is required so a rollback never fans out across databases by accident.

func HandleInit

func HandleInit()

func HandleMigrate

func HandleMigrate(cliURL string, dbName string)

HandleMigrate runs pending migrations. dbName selects a single configured database; when empty, every configured database is migrated in turn.

func HandleUpdate

func HandleUpdate(currentVersion string)

Types

type GithubRelease

type GithubRelease struct {
	TagName string `json:"tag_name"`
	Assets  []struct {
		Name               string `json:"name"`
		BrowserDownloadURL string `json:"browser_download_url"`
	} `json:"assets"`
}

GithubRelease represents the structure of a GitHub release from the API

Jump to

Keyboard shortcuts

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