Ecto tasks: Resolve relative path using the application directory
instead of cwd and load the application before doing anything In OTP releases cwd != app directory and the configuration is read only if the application is loaded
This commit is contained in:
parent
ddd04d1c52
commit
ebee9f59d8
4 changed files with 18 additions and 1 deletions
|
|
@ -9,6 +9,10 @@ defmodule Mix.Pleroma do
|
|||
{:ok, _} = Application.ensure_all_started(:pleroma)
|
||||
end
|
||||
|
||||
def load_pleroma do
|
||||
Application.load(:pleroma)
|
||||
end
|
||||
|
||||
def get_option(options, opt, prompt, defval \\ nil, defname \\ nil) do
|
||||
Keyword.get(options, opt) || shell_prompt(prompt, defval, defname)
|
||||
end
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue