Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 6 additions & 3 deletions lib/mix/lib/mix/tasks/app.config.ex
Original file line number Diff line number Diff line change
Expand Up @@ -31,10 +31,13 @@ defmodule Mix.Tasks.App.Config do
{opts, _, _} = OptionParser.parse(args, switches: @switches)

config = Mix.Project.config()
runtime = config[:config_path] |> Path.dirname() |> Path.join("runtime.exs")

if File.exists?(runtime) do
Mix.Tasks.Loadconfig.load_runtime(runtime)
unless "--no-runtime-exs" in args do
runtime = config[:config_path] |> Path.dirname() |> Path.join("runtime.exs")

if File.exists?(runtime) do
Mix.Tasks.Loadconfig.load_runtime(runtime)
end
end

if opts[:preload_modules] do
Expand Down
3 changes: 2 additions & 1 deletion lib/mix/lib/mix/tasks/run.ex
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,8 @@ defmodule Mix.Tasks.Run do
archives_check: :boolean,
elixir_version_check: :boolean,
parallel_require: :keep,
preload_modules: :boolean
preload_modules: :boolean,
runtime_exs: :boolean
],
return_separator: true
)
Expand Down