flyway-migrations
БесплатноБез исполняемых скриптовНе проверенFlyway SQL migration patterns for Xeres including naming conventions, H2 database patterns, enum types, foreign keys, and best practices.
от zapek★ 224 звезды на GitHubОб этом скилле
Flyway Migration Patterns for Xeres
Migration Location
app/src/main/resources/db/migration/
Naming Convention
V<major>_<minor>_<timestamp>__<description>.sql
Examples:
V00_0_1_202001232214__InitDb.sqlV00_0_32_202603092327__AddIndices.sql
Table Creation Pattern
CREATE TABLE profile (
id BIGINT GENERATED BY DEFAULT AS IDENTITY PRIMARY KEY,
name VARCHAR(255) NOT NULL,
pgp_id BIGINT,
created TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP,
CONSTRAINT profile_pkey PRIMARY KEY (id)
);
CREATE INDEX idx_profile_name ON profile(name);
Enum Types
CREATE TYPE trust_level AS ENUM ('UNKNOWN', 'NEVER', 'MARGINAL', 'FULLY', 'ULTIMATE');
ALTER TABLE profile ADD COLUMN trust trust_level NOT NULL DEFAULT 'UNKNOWN';
Foreign Keys
ALTER TABLE contact
ADD CONSTRAINT fk_contact_profile
FOREIGN KEY (profile_id) REFERENCES profile(id)
ON DELETE CASCADE;
Best Practices
- Separate index creation from table creation
- Name all constraints explicitly for easier debugging
- Use
BIGINTfor IDs withGENERATED BY DEFAULT AS IDENTITY - Include
NOT NULLconstraints where appropriate - Default values for optional columns
- One concern per migration when possible
- Timestamp precision must always be of TIMESTAMP(9)
Rolling Back
Flyway does not support downward (undo) migrations in the open-source edition. To revert a change, create a new forward migration that undoes it, following the standard naming convention:
-- V00_0_34_202605010000__DropLastSeen.sql
ALTER TABLE location DROP COLUMN IF EXISTS last_seen;
Testing Migrations
Flyway runs automatically on application startup with H2 database.
Установить flyway-migrations в Claude Code и Claude Desktop
Зарегайся, чтобы установить скилл
Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.
- Открой команду установки в одну строку
- Сохраняй скиллы в синхронизируемую библиотеку
- Уведомления, когда скиллы обновляются
Разрешённые инструменты
Инструменты, которые скиллу разрешено вызывать.
Без ограничений — скилл может использовать любой инструмент.
FAQ
Что делает скилл flyway-migrations?
Flyway SQL migration patterns for Xeres including naming conventions, H2 database patterns, enum types, foreign keys, and best practices.
Как установить скилл flyway-migrations?
Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.
Скилл flyway-migrations запускает скрипты?
Нет, скилл состоит только из инструкций (SKILL.md), без исполняемых скриптов.
Похожие скиллы
theme-factory
Toolkit for styling artifacts with a theme. These artifacts can be slides, docs, reportings, HTML landing pages, etc. There are 10 pre-set themes with…
от Anthropicaccess
Manage Discord channel access — approve pairings, edit allowlists, set DM/group policy. Use when the user asks to pair, approve someone, check who's allowed…
от Anthropicconfigure
Set up the Discord channel — save the bot token and review access policy. Use when the user pastes a Discord bot token, asks to configure Discord, asks "how…
от Anthropicaccess
Manage iMessage channel access — approve pairings, edit allowlists, set DM/group policy. Use when the user asks to pair, approve someone, check who's allowed…
от Anthropic