Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Like many other people there is a definte use case for things like a history of migrations, among other things.
So after seeing the other requests on here I have come up with a way of emitting triggers that can be used to add any additional functionality that people may require. These triggers do not affect the running of the CLI and are for use by people wanting to extend functionality.
I have added an example for MySQL in the file
database/mysql/examples/triggers/main.go
In
migrate.go
I have also added anOptions
struct to allow for easy extensability in future - maybe this should be its own PR?