go-goose

Plan and execute SQL and Go database migrations with goose CLI.

21|1|Updated Jan 8, 2026
One-click install
npx skills add https://github.com/metalagman/agent-skills --skill go-goose
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: go-goose
Source: https://github.com/metalagman/agent-skills/tree/main/go-goose
Command: npx skills add https://github.com/metalagman/agent-skills --skill go-goose

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve?

Goose enables teams to manage database migrations with a cohesive CLI and Go library, providing deterministic Up/Down execution, support for embedded migrations, and provider-based execution to keep schemas consistent across environments.

Core Features & Use Cases

  • CLI-driven migrations: up, down, status, create, and versioning to manage schema changes across databases.
  • Library & Provider API: embed, run, and track migrations from within Go applications using Goose APIs.
  • Embedded migrations: read migrations from embedded FS and apply them at runtime.
  • Versioning & annotations: follow goose's annotation rules and maintain ordered migrations for team collaboration.
  • Use Case: migrate a PostgreSQL database by applying a set of SQL and Go migrations with proper rollback support.

Quick Start

Install the goose tooling, initialize a migrations directory, and create your first migration with goose create to begin managing your database schema.

Frequently Asked Questions about go-goose

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

FAQPage Schema
How do I manage database migrations in Go using goose?

Goose manages database migrations in Go by providing a CLI and library to plan and execute deterministic Up/Down schema changes across PostgreSQL, MySQL, and SQLite environments. It supports both SQL and Go-based migration files.

Can I embed goose migrations directly in a Go application?

Yes, you can embed goose migrations in a Go application. Goose supports reading migrations from an embedded filesystem and applying them at runtime using its library and provider-based execution APIs.

Does goose support database rollback logic for schema changes?

Goose supports database rollback logic through deterministic Down migrations. You can reverse schema changes applied by Up migrations across PostgreSQL, MySQL, and SQLite using standard goose CLI commands or library APIs.

What is the best way to version database migrations for team collaboration?

The best way to version database migrations for team collaboration is using goose's standard annotation rules. Goose maintains ordered, versioned migration files to ensure consistent schema tracking and deterministic execution across team environments.

How do I apply SQL and Go migrations to PostgreSQL with goose?

You apply SQL and Go migrations to PostgreSQL with goose by initializing a migrations directory and using the CLI up command or the provider API. Goose executes the ordered migration files to update your database schema with rollback support.

When should I use goose provider-based execution for migrations?

Use goose provider-based execution for migrations when you need to run and track schema changes directly from within a Go application. This approach leverages library APIs to apply embedded migrations at runtime instead of relying on the CLI.