Do not hardcode fork name into version name
fixes build errors in certain situations
This commit is contained in:
parent
3a7967d331
commit
8376ca1dda
1 changed files with 3 additions and 3 deletions
6
mix.exs
6
mix.exs
|
@ -4,7 +4,7 @@ defmodule Pleroma.Mixfile do
|
||||||
def project do
|
def project do
|
||||||
[
|
[
|
||||||
app: :pleroma,
|
app: :pleroma,
|
||||||
version: version("3.10.3+bnakkoma"),
|
version: version("3.10.3"),
|
||||||
elixir: "~> 1.14",
|
elixir: "~> 1.14",
|
||||||
elixirc_paths: elixirc_paths(Mix.env()),
|
elixirc_paths: elixirc_paths(Mix.env()),
|
||||||
compilers: Mix.compilers(),
|
compilers: Mix.compilers(),
|
||||||
|
@ -279,7 +279,7 @@ defp version(version) do
|
||||||
branch_name <- String.trim(branch_name),
|
branch_name <- String.trim(branch_name),
|
||||||
branch_name <- System.get_env("PLEROMA_BUILD_BRANCH") || branch_name,
|
branch_name <- System.get_env("PLEROMA_BUILD_BRANCH") || branch_name,
|
||||||
true <-
|
true <-
|
||||||
!Enum.any?(["master", "HEAD", "release/", "stable"], fn name ->
|
!Enum.any?(["master", "HEAD", "release/", "stable", "bnakkoma"], fn name ->
|
||||||
String.starts_with?(name, branch_name)
|
String.starts_with?(name, branch_name)
|
||||||
end) do
|
end) do
|
||||||
branch_name =
|
branch_name =
|
||||||
|
@ -296,7 +296,7 @@ defp version(version) do
|
||||||
cond do
|
cond do
|
||||||
name = Application.get_env(:pleroma, :build_name) -> name
|
name = Application.get_env(:pleroma, :build_name) -> name
|
||||||
name = System.get_env("PLEROMA_BUILD_NAME") -> name
|
name = System.get_env("PLEROMA_BUILD_NAME") -> name
|
||||||
true -> nil
|
true -> "bnakkoma"
|
||||||
end
|
end
|
||||||
|
|
||||||
env_name = if Mix.env() != :prod, do: to_string(Mix.env())
|
env_name = if Mix.env() != :prod, do: to_string(Mix.env())
|
||||||
|
|
Loading…
Reference in a new issue