From e3173a279dad89dfce6eae89368ad3ba180c0490 Mon Sep 17 00:00:00 2001 From: Alex Gleason Date: Wed, 19 May 2021 14:27:02 -0500 Subject: [PATCH] Put Plugs in runtime mode in :dev, :test to speed up recompilation --- config/dev.exs | 4 ++++ config/test.exs | 4 ++++ 2 files changed, 8 insertions(+) diff --git a/config/dev.exs b/config/dev.exs index 4faaeff5b..8e7d5c587 100644 --- a/config/dev.exs +++ b/config/dev.exs @@ -54,6 +54,10 @@ config :pleroma, Pleroma.Repo, config :pleroma, Pleroma.Web.ApiSpec.CastAndValidate, strict: true +# Reduce recompilation time +# https://dashbit.co/blog/speeding-up-re-compilation-of-elixir-projects +config :phoenix, :plug_init_mode, :runtime + if File.exists?("./config/dev.secret.exs") do import_config "dev.secret.exs" else diff --git a/config/test.exs b/config/test.exs index 87396a88d..007951097 100644 --- a/config/test.exs +++ b/config/test.exs @@ -133,6 +133,10 @@ config :pleroma, :side_effects, ap_streamer: Pleroma.Web.ActivityPub.ActivityPubMock, logger: Pleroma.LoggerMock +# Reduce recompilation time +# https://dashbit.co/blog/speeding-up-re-compilation-of-elixir-projects +config :phoenix, :plug_init_mode, :runtime + if File.exists?("./config/test.secret.exs") do import_config "test.secret.exs" else