db-migrations

Automate database migrations for Go projects using goose or golang-migrate.

1|1|Updated Mar 6, 2026
One-click install
npx skills add https://github.com/dennisonbertram/go-agent-harness --skill db-migrations-dennisonbertram
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: db-migrations
Source: https://github.com/dennisonbertram/go-agent-harness/tree/main/skills/db-migrations
Command: npx skills add https://github.com/dennisonbertram/go-agent-harness --skill db-migrations-dennisonbertram

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Addresses the pain of managing database schema changes in Go projects by providing a unified workflow for creating, applying, and rolling back migrations using Goose or golang-migrate.

Core Features & Use Cases

  • Supports Goose and golang-migrate workflows for SQL and Go migrations.
  • Provides a standard migration lifecycle: create, Up, Down, status, and rollback across local and CI environments.
  • Encourages best practices like transactional migrations and versioned files.

Quick Start

Initialize migrations by creating the migrations directory and running Up migrations with goose or golang-migrate.

Frequently Asked Questions about db-migrations

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I automate database migrations in a Go project?

Automate database migrations in a Go project by applying a standard workflow with Up, Down, and Status commands using either Goose or golang-migrate. This enforces best practices like versioned files and transactional migrations across local and CI environments.

Can I roll back SQL schema changes safely using golang-migrate?

Yes, you can roll back SQL schema changes safely using golang-migrate with built-in Down commands and version tracking. This provides safe rollback capabilities for both SQL-based and Go-based migrations while maintaining a standard migration lifecycle.

Does this database migration workflow support both SQL and Go based migration files?

Yes, the database migration workflow supports both SQL-based and Go-based migration files when using Goose or golang-migrate. It enforces a standard lifecycle of creating, applying, and rolling back migrations with versioned files.

What is the best way to manage database schema changes in Go across local and CI environments?

The best way to manage database schema changes in Go is using a unified migration workflow with Goose or golang-migrate. It enforces standard create, Up, Down, and status commands with version tracking, ensuring consistent schema management across local and CI environments.

How do I create and apply versioned database migrations with Goose?

Create and apply versioned database migrations with Goose by initializing a migrations directory and running the Up command. This enforces a standard migration workflow with version tracking, supporting safe rollbacks and transactional migrations for your Go project.

Why use a standard migration lifecycle for database schema changes in Golang?

Use a standard migration lifecycle for database schema changes in Golang to ensure safe rollback capabilities, accurate version tracking, and consistent application of versioned files. It addresses the pain of managing schema changes by enforcing transactional migrations across environments.