Skip to content

v0.1.0

Choose a tag to compare

@tbson tbson released this 17 Nov 08:59
· 4 commits to main since this release

First release of the schemity command line tool and the Schemity Migration Check action.

It reports what SQL migration files do, before they run, with no database and no credentials:

  • What each statement does to existing data: drops it, can fail on it, rewrites the table, holds back other statements, and which other tables it reaches through foreign keys.
  • Design findings the change introduces: 46 rules, such as a foreign key with no index or a table with no primary key. schemity rules --dialect <name> lists them.

The schema a migration runs against is rebuilt from the older migration files in the repo, or from a schema dump (pg_dump --schema-only, structure.sql). Nothing is executed and nothing is sent anywhere.

Use in a workflow

- uses: actions/checkout@v6
- uses: schemity/ci@v1
  with:
    dialect: postgres
    migrations: db/migrations

The job passes whatever the report says, unless fail-on is set (for example fail-on: loses-data,can-fail).

Databases

PostgreSQL, MySQL, MariaDB, SQL Server, SQLite, Snowflake, CockroachDB.

Downloads

File For
schemity-x86_64-unknown-linux-musl.tar.gz Linux x64
schemity-aarch64-unknown-linux-musl.tar.gz Linux ARM64
schemity-aarch64-apple-darwin.tar.gz macOS on Apple silicon

Each archive holds the schemity binary, its license and the licenses of the open source software in it. SHA-256 sums are in checksums.txt.

Not in this release

  • Windows and Intel macOS builds.
  • Finding where a schema dump ends: with schema, name the newer migrations in before.
  • Row counts and views: there is no database to ask. The Schemity desktop app reports those against a live connection.