New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
dialect/sql/schema: add method to create a named versioned migration … #2385
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
masseelch
force-pushed
the
migrate/named
branch
from
March 10, 2022 15:15
96909d6
to
b991654
Compare
a8m
reviewed
Mar 10, 2022
doc/md/versioned-migrations.md
Outdated
Comment on lines
142
to
145
// You can use the following method to give the migration files a name. | ||
// if err := m.NamedDiff(context.Background(), "migration_name", tbls...); err != nil { | ||
// log.Fatalln(err) | ||
// } |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fix weird indentation
a8m
approved these changes
Mar 10, 2022
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
💯
zeevmoney
added a commit
to zeevmoney/ent
that referenced
this pull request
Mar 15, 2022
* master: doc/website/blog: versioned migrations (ent#2387) build(deps): bump github.com/spf13/cobra from 1.3.0 to 1.4.0 (ent#2386) go: upgrade atlas for tidb support (ent#2394) dialect/sql/schema: add method to create a named versioned migration … (ent#2385) docs: add maorlipchuk as a contributor for code (ent#2381) entc/gen: set Ref and Inverse for edge contains both From and To schema/field: expose RType.Implements method (ent#2379) docs: add imhuytq as a contributor for code (ent#2378) dialect/sql/schema: add name to versioned migration files (ent#2375) all: update atlasgo.io to latest (ent#2376) dialect/sql/schema: fix bug in atlas integration when working WithDropIndex/WithDropColumn (ent#2374) build(deps): bump actions/checkout from 2.4.0 to 3 (ent#2372) build(deps): bump actions/setup-node from 2.5.1 to 3 (ent#2365)
gitlawr
pushed a commit
to gitlawr/ent
that referenced
this pull request
Apr 13, 2022
ent#2385) * dialect/sql/schema: add method to create a named versioned migration file * doc/md: documentation for named versioned migrations * entc/gen/template/dialect/sql/feature: add NamedDiff method to create named versioned migration files * all: go generate * doc/md: apply CR
gitlawr
pushed a commit
to seal-io/ent
that referenced
this pull request
Apr 13, 2022
ent#2385) * dialect/sql/schema: add method to create a named versioned migration file * doc/md: documentation for named versioned migrations * entc/gen/template/dialect/sql/feature: add NamedDiff method to create named versioned migration files * all: go generate * doc/md: apply CR
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
…file
As suggested in #2382 this adds a new method
NamedDiff()
to create migration files with a name.