37 lines
620 B
Plaintext
37 lines
620 B
Plaintext
package migrations
|
|
|
|
import (
|
|
"context"
|
|
"time"
|
|
|
|
"git.handmade.network/hmn/hmn/src/migration/types"
|
|
"git.handmade.network/hmn/hmn/src/oops"
|
|
"github.com/jackc/pgx/v4"
|
|
)
|
|
|
|
func init() {
|
|
registerMigration(%NAME%{})
|
|
}
|
|
|
|
type %NAME% struct{}
|
|
|
|
func (m %NAME%) Version() types.MigrationVersion {
|
|
return types.MigrationVersion(%DATE%)
|
|
}
|
|
|
|
func (m %NAME%) Name() string {
|
|
return "%NAME%"
|
|
}
|
|
|
|
func (m %NAME%) Description() string {
|
|
return %DESCRIPTION%
|
|
}
|
|
|
|
func (m %NAME%) Up(ctx context.Context, tx pgx.Tx) error {
|
|
panic("Implement me")
|
|
}
|
|
|
|
func (m %NAME%) Down(ctx context.Context, tx pgx.Tx) error {
|
|
panic("Implement me")
|
|
}
|