Skip to content
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

Specifying a target Migrations directory. #24

Closed
AlonCG opened this issue Aug 10, 2016 · 10 comments
Closed

Specifying a target Migrations directory. #24

AlonCG opened this issue Aug 10, 2016 · 10 comments

Comments

@AlonCG
Copy link

AlonCG commented Aug 10, 2016

Is it possible to specify a target Migrations directory?

Currently ... even when my configuration lists a non-default ("Data\Migrations") folder, the migrations are still added to the default "Migrations" folder.

I see in your "Executor" that the folder appears hard-coded, any way to add a switch to enable another location? It is not overly critical, as I can just move the migrations, but it would be nice.

Thanks for all your work and assistance.

@mrahhal
Copy link
Owner

mrahhal commented Aug 10, 2016

When I started working on this I just enabled what is mostly critical for apps to work and just went with it. So yeah there are a couple of hard coded stuff. I planed on enabling more features in the underlying migrator but I just didn't see an actual necessity.

But It has been a while since I did a review on this so I guess I should do a couple of those little wanted features and do an update. Keep this open and I'll let you know when I update.

@AlonCG
Copy link
Author

AlonCG commented Aug 10, 2016

Awesome thanks!

@mrahhal
Copy link
Owner

mrahhal commented Aug 10, 2016

Okay, so. You'll have to specify your migrations dir in both the enable and the add command.

So:

dotnet ef migrations enable -o Foo
dotnet ef migrations add MigrationName -o Foo

@AlonCG
Copy link
Author

AlonCG commented Aug 10, 2016

Yes ... that seems like the MS implementation (according to their docs).

@mrahhal
Copy link
Owner

mrahhal commented Aug 10, 2016

I'll let you know when I do a package update. (probably very soon)

@AlonCG
Copy link
Author

AlonCG commented Aug 10, 2016

Killer, thanks!

@mrahhal
Copy link
Owner

mrahhal commented Aug 10, 2016

@AlonCG 1.0.1

@AlonCG
Copy link
Author

AlonCG commented Aug 10, 2016

Awesome! Thanks again and could not have even dreamed of a better response time! I will try it out in a few minutes.

@mrahhal
Copy link
Owner

mrahhal commented Aug 10, 2016

Haha don't worry about it. Glad to help.

@AlonCG
Copy link
Author

AlonCG commented Aug 10, 2016

Thanks again ... "-o" working so far!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants