Skip to content

Releases: graphile/migrate

v0.3.0 - don't clobber settings

13 May 15:00
Compare
Choose a tag to compare

This release will throw if you have incompatible copies of :DATABASE_OWNER / :DATABASE_NAME placeholders, or GM_* environmental variables set - it no longer simply clobbers them.

v0.2.0 - "before" actions

27 Apr 10:17
Compare
Choose a tag to compare

We already had "after" actions; now we also have "before" actions - thanks @hos!

Improved error messages - thanks @PizzaPartyInc!

Also extended the range of pg versions supported, fixing Node v14 support.

v0.1.0 - simply "experimental" 😉

17 Mar 20:29
Compare
Choose a tag to compare
  • Status changed from "HIGHLY EXPERIMENTAL" to simply "EXPERIMENTAL" 😉
  • Add support for "the current migration" to be a directory if desired (@benjie expanding on PR by @lukaspili)
  • Add support for naming commits if desired (@benjie expanding on PR by @pixelpax)
  • Add ability to run afterReset SQL actions as superuser
  • Add ability to run graphile-migrate status without requiring a database connection
  • Wrap migrations with advisory locks incase two servers attempt to migrate at the same time
  • Use a proper CLI parser, so extraneous arguments now throw an error
  • Add new commands:
    • init to set up a new environment
    • compile to compile an SQL file (filling out placeholders) and output the result
    • run to compile and run an SQL file
    • completion to install CLI autocompletion (untested)
  • Expose more configuration options:
    • migrationsFolder to choose where migrations go
    • blankMigrationContent to choose what goes into the current migration when it's created
  • Committed migrations are now chmodded to 0440 (world and group read only)
  • More consistent header handling (and documentation)
  • Documentation
    • All commands now self-documenting with --help
    • Committed migration file and other SQL files documented in FORMATS.md
    • Some of the types now have documentation
    • Be more consistent (and explain!) about "root" vs "superuser"
  • Lots and lots and lots of housekeeping
    • Tests
    • Module updates (@singingwolfboy)
    • Stronger linting
    • Broader linting
    • Sorted imports
    • Stronger types

BREAKING CHANGES

Potential checksum breakage

Content to be checksummed is now normalized by trimming all surrounding
whitespace and then appending a single newline. If your migrations were not
nicely formatted like this then the checksums may have changed which will
give you issues on validation. If you're affected by this please reach out to
me on Discord: http://discord.gg/graphile

"The best time to plant a tree is twenty years ago. The second best time is now."

graphile-migrate --force -> graphile-migrate --forceActions

I renamed this CLI flag and reserve --force for future usage.

graphile-migrate reset -> graphile-migrate reset --erase

The --erase flag is now required to make it clear you're losing all your data by running that command. Be safe!

v0.0.18

27 Jan 12:47
Compare
Choose a tag to compare

Fixes some docs and allows you to opt out of graphile_migrate schema auto-migration in case your migrator-role does not have permission to do this.

v0.0.17

01 Oct 11:01
Compare
Choose a tag to compare

Solves an issue with watch mode on Linux (where watching could be broken by a git stash command).

v0.0.16

30 Sep 15:52
Compare
Choose a tag to compare

Add newline after blank current.sql content.

v0.0.15

30 Sep 14:02
Compare
Choose a tag to compare

New uncommit command.

v0.0.14

30 Sep 11:42
Compare
Choose a tag to compare

Fix issue where the database name and owner name were not escaped correctly.

v0.0.13

30 Sep 11:42
Compare
Choose a tag to compare

Fix bug in 0.0.12 where the untransformed query was tracked, so any current.sql that used variables still showed up as different and was re-ran unnecessarily.

v0.0.12

30 Sep 11:41
Compare
Choose a tag to compare
  • Only re-run current.sql when its content has changed.
  • Remove TSLint in favour of ESLint
  • Update dependencies
  • Refactor tests