Skip to content

Releases: maragudk/migrate

v0.6.0 - Upgrade to Go 1.18

10 Sep 09:59
0f96189
Compare
Choose a tag to compare

What's Changed

Full Changelog: v0.5.0...v0.6.0

v0.5.0 - Move module to maragu.dev/migrate

10 Sep 09:30
Compare
Choose a tag to compare

Please update your imports to use maragu.dev/migrate instead of github.com/maragudk/migrate. Steps:

  1. go get maragu.dev/migrate
  2. Replace All in your project, github.com/maragudk/migrate -> maragu.dev/migrate
  3. go mod tidy

What's Changed

Full Changelog: v0.4.3...v0.5.0

Add better error messages

20 Oct 11:25
4f7ed24
Compare
Choose a tag to compare
Pre-release

Error messages are now more descriptive and upstream errors are wrapped properly.

Allow . (full stop) in table name

28 Mar 07:59
b86d7a9
Compare
Choose a tag to compare
Pre-release

This is a minor release, which adds a feature to allow . (full stop) characters in the migration table name (see issue #23). Thanks to @mirkoperillo for suggesting and implementing it!

Add before/after callbacks

18 Nov 14:14
Compare
Choose a tag to compare
Pre-release

This release adds optional functions in the migrate.Options that, if set, are called before and after each migration. The functions are passed the context, the transaction, and the version string. If the callback errors, the current migration is aborted and the transaction rolled back.

Also fixed an internal bug that didn't report errors back if a panic occurred inside a transaction.

New uses Options struct

05 Jul 12:53
275bddd
Compare
Choose a tag to compare
Pre-release

BREAKING: New now only takes an Options struct.

Add Migrator.MigrateTo and Up/Down/To convenience functions

25 Jun 21:02
b077d49
Compare
Choose a tag to compare
Add Migrator.MigrateTo and To (#14)

Fixes #2.

Placeholder is gone

17 Jun 19:41
8282b29
Compare
Choose a tag to compare
Placeholder is gone Pre-release
Pre-release

Breaking: Migrator.Placeholder is gone again, because it wasn't needed after all. This simplifies the API.

If you used the library in the brief time it existed, just delete its usage, and you should be good to go.

Add MySQL/MariaDB support

17 Jun 09:30
85e2dc9
Compare
Choose a tag to compare
Pre-release
v0.2.1

Add CI badge to readme (#8)

Drop the path

16 Jun 17:33
Compare
Choose a tag to compare
Drop the path Pre-release
Pre-release

Migrator.Path is gone, use fs.Sub if you need a different directory.