SQL migration tool with PostgreSQL/MySQL/MariaDB/Oracle/SQLite/MSSQL/ClickHouse/TiDB/Redshift support.
- User Guide (中文)
- User Guide (English)
- User Guide (繁體中文)
- User Guide (日本語)
- User Guide (한국어)
- User Guide (Español)
- User Guide (Français)
- User Guide (Deutsch)
- User Guide (Português do Brasil)
- User Guide (Русский)
- User Guide (العربية)
- User Guide (हिन्दी)
- Changelog
go install github.com/exc-works/migrate/cmd/migrate@latestmigrate new config
migrate new version init_users
migrate create
migrate up
migrate status
migrate status --output jsongo test ./...
go test -tags=integration ./...Run a specific integration dialect:
INTEGRATION_DB=sqlite go test -tags=integration ./integrationtest/...
INTEGRATION_DB=postgres,mysql,mariadb go test -tags=integration ./integrationtest/...Run Oracle integration (requires reachable Oracle DSN):
INTEGRATION_DB=oracle INTEGRATION_ORACLE_DSN='<oracle dsn>' go test -tags=integration ./integrationtest/..../scripts/install-git-hooks.shThis enables repository hooks via core.hooksPath=.githooks and blocks commits that add:
- private key material
- absolute filesystem paths (Unix and Windows)
- hardcoded credentials (
password/token/secret)
For remote enforcement, configure protected branch push protection or server-side pre-receive scanning.