diff options
author | Alex Gleason <alex@alexgleason.me> | 2021-12-23 16:19:57 +0000 |
---|---|---|
committer | Alex Gleason <alex@alexgleason.me> | 2021-12-23 16:19:57 +0000 |
commit | 1fa616638b8823a6cc0d67d0354cc179da5943f8 (patch) | |
tree | 26ed72aab0bba07ce312b0c5b54ad91350fca78f | |
parent | 2caade10dfc6ca06d55b90768c57012d56c776ed (diff) | |
parent | 079afd32d86ae5211106cdc9e1916c6640bedd39 (diff) | |
download | pleroma-1fa616638b8823a6cc0d67d0354cc179da5943f8.tar.gz |
Merge branch 'warnings-as-errors' into 'develop'
Enable :warnings_as_errors for CI only
See merge request pleroma/pleroma!3474
-rw-r--r-- | mix.exs | 5 |
1 files changed, 2 insertions, 3 deletions
@@ -8,7 +8,7 @@ defmodule Pleroma.Mixfile do elixir: "~> 1.9", elixirc_paths: elixirc_paths(Mix.env()), compilers: [:phoenix, :gettext] ++ Mix.compilers(), - elixirc_options: [warnings_as_errors: warnings_as_errors(Mix.env())], + elixirc_options: [warnings_as_errors: warnings_as_errors()], xref: [exclude: [:eldap]], start_permanent: Mix.env() == :prod, aliases: aliases(), @@ -91,8 +91,7 @@ defmodule Pleroma.Mixfile do defp elixirc_paths(:test), do: ["lib", "test/support"] defp elixirc_paths(_), do: ["lib"] - defp warnings_as_errors(:prod), do: false - defp warnings_as_errors(_), do: true + defp warnings_as_errors, do: System.get_env("CI") == "true" # Specifies OAuth dependencies. defp oauth_deps do |