migrate

package
v0.3.0 Latest Latest
Warning

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

Go to latest
Published: Aug 28, 2026 License: MIT Imports: 9 Imported by: 0

Documentation

Overview

Package migrate applies ragit's schema migrations.

It exists as its own package so that both the public entry point (ragit.Migrate) and the test harness can use it without the test harness having to import the root package it is used to test.

Index

Constants

View Source
const TableName = "ragit_migrations"

TableName is ragit's own schema-version table. It is deliberately not goose's default goose_db_version: a host application running its own goose sequence over its own tables must be able to upgrade ragit independently, without the two lines colliding on a version number. Same reasoning behind River's separate river_migration table.

Variables

This section is empty.

Functions

func Down

func Down(ctx context.Context, pool *pgxpool.Pool, fsys fs.FS) error

Down rolls back the most recent migration in fsys.

func Up

func Up(ctx context.Context, pool *pgxpool.Pool, fsys fs.FS) error

Up applies every outstanding migration in fsys.

Types

This section is empty.

Jump to

Keyboard shortcuts

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