MCP HubMCP Hub
スキル一覧に戻る

Create database migration

majiayu000
更新日 2 days ago
19 閲覧
58
9
58
GitHubで表示
メタdata

について

このスキルは、GhostのMySQLスキーマに対してテーブルやカラムの追加などのデータベースマイグレーションを作成する開発者を支援します。`slimer` CLIツールを使用して初期マイグレーションファイルを生成し、適切なユーティリティ関数で更新する手順を案内します。バージョン管理された方法でGhostデータベース構造を変更する必要がある場合にご利用ください。

クイックインストール

Claude Code

推奨
プラグインコマンド推奨
/plugin add https://github.com/majiayu000/claude-skill-registry
Git クローン代替
git clone https://github.com/majiayu000/claude-skill-registry.git ~/.claude/skills/Create database migration

このコマンドをClaude Codeにコピー&ペーストしてスキルをインストールします

ドキュメント

Create Database Migration

Instructions

  1. Change directories into ghost/core: cd ghost/core
  2. Create a new, empty migration file using slimer: slimer migration <name-of-database-migration>. IMPORTANT: do not create the migration file manually; always use slimer to create the initial empty migration file.
  3. The above command will create a new directory in ghost/core/core/server/data/migrations/versions if needed, and create the empty migration file with the appropriate name.
  4. Update the migration file with the changes you want to make in the database, following the existing patterns in the codebase. Where appropriate, prefer to use the utility functions in ghost/core/core/server/data/migrations/utils/*.
  5. Update the schema definition file in ghost/core/core/server/data/schema/schema.js, and make sure it aligns with the latest changes from the migration.
  6. Test the migration manually: yarn knex-migrator migrate --v {version directory} --force
  7. If adding or dropping a table, update ghost/core/core/server/data/exporter/table-lists.js as appropriate.
  8. Run the schema integrity test, and update the hash: yarn test:single test/unit/server/data/schema/integrity.test.js
  9. Run unit tests in Ghost core, and iterate until they pass: cd ghost/core && yarn test:unit

Examples

See examples.md for example migrations.

Rules

See rules.md for rules that should always be followed when creating database migrations.

GitHub リポジトリ

majiayu000/claude-skill-registry
パス: skills/create-database-migration

関連スキル

content-collections

メタ

This skill provides a production-tested setup for Content Collections, a TypeScript-first tool that transforms Markdown/MDX files into type-safe data collections with Zod validation. Use it when building blogs, documentation sites, or content-heavy Vite + React applications to ensure type safety and automatic content validation. It covers everything from Vite plugin configuration and MDX compilation to deployment optimization and schema validation.

スキルを見る

polymarket

メタ

This skill enables developers to build applications with the Polymarket prediction markets platform, including API integration for trading and market data. It also provides real-time data streaming via WebSocket to monitor live trades and market activity. Use it for implementing trading strategies or creating tools that process live market updates.

スキルを見る

hybrid-cloud-networking

メタ

This skill configures secure hybrid cloud networking between on-premises infrastructure and cloud platforms like AWS, Azure, and GCP. Use it when connecting data centers to the cloud, building hybrid architectures, or implementing secure cross-premises connectivity. It supports key capabilities such as VPNs and dedicated connections like AWS Direct Connect for high-performance, reliable setups.

スキルを見る

llamaindex

メタ

LlamaIndex is a data framework for building RAG-powered LLM applications, specializing in document ingestion, indexing, and querying. It provides key features like vector indices, query engines, and agents, and supports over 300 data connectors. Use it for document Q&A, chatbots, and knowledge retrieval when building data-centric applications.

スキルを見る