The short answer is that in Elixir releases you will be able to do:

    bin/my_app eval "MyApp.ReleaseTasks.migrate"

So the code in Distillery still works, you will have to adjust it a bit
though and remove the arg processing bit, as you can call the functions
directly . We will probably have a section about it in the Phoenix guides
once Elixir v1.9 is out.

*José Valim*
www.plataformatec.com.br
Skype: jv.ptec
Founder and Director of R&D


On Sat, May 4, 2019 at 4:45 PM <[email protected]> wrote:

> A common task to run in a build environment, but often separately from
> your actual application code, is database migrations. Distillery provides a
> suggested way of running them here:
> https://hexdocs.pm/distillery/guides/running_migrations.html and it's
> frequently linked to in the community. When you think about it, the
> Distillery guide is basically just convenience commands around evaluating
> an mfa and it also mentions using rpc as an alternative.
>
> I'm wondering if there's been any thought into how migrations would be
> conveniently run with 1.9 releases. It would be helpful to new users if we
> could provide a "best practice" or at least suggested way of handling this.
> I've already seen this question pop up several times.
>
> It probably shouldn't be in the official documentation, since not everyone
> uses ecto migrations and ecto is not a part of the core language, but I'm
> curious if someone has ideas on how this could be done in an elegant way.
> Maybe it could be added to the ecto documentation, now that releases are a
> core part of the language.
>
> --
> You received this message because you are subscribed to the Google Groups
> "elixir-lang-core" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to [email protected].
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/elixir-lang-core/a463f2f1-332c-40e2-b570-8feccaf5b2ce%40googlegroups.com
> <https://groups.google.com/d/msgid/elixir-lang-core/a463f2f1-332c-40e2-b570-8feccaf5b2ce%40googlegroups.com?utm_medium=email&utm_source=footer>
> .
> For more options, visit https://groups.google.com/d/optout.
>

-- 
You received this message because you are subscribed to the Google Groups 
"elixir-lang-core" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/elixir-lang-core/CAGnRm4Jed-oWMBKyq%2Bahz%2BuyDemjgPrq0eD%2BDjtz6LLYGAkpmw%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to