migrate

package
v1.0.2-gitspaces-beta Latest Latest
Warning

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

Go to latest
Published: Jul 22, 2024 License: Apache-2.0 Imports: 15 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Current

func Current(ctx context.Context, db *sqlx.DB) (string, error)

Current returns the current version ID (the latest migration applied) of the database.

func Migrate

func Migrate(ctx context.Context, db *sqlx.DB) error

Migrate performs the database migration.

func To

func To(ctx context.Context, db *sqlx.DB, version string) error

To performs the database migration to the specific version.

func WebhookDisplayNameToIdentifier

func WebhookDisplayNameToIdentifier(displayName string, randomize bool) (string, error)

WebhookDisplayNameToIdentifier migrates the provided displayname to a webhook identifier. If randomize is true, a random suffix is added to randomize the identifier.

Types

This section is empty.

Jump to

Keyboard shortcuts

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