-
-
Notifications
You must be signed in to change notification settings - Fork 97
Expand file tree
/
Copy pathmix.exs
More file actions
68 lines (59 loc) · 1.65 KB
/
mix.exs
File metadata and controls
68 lines (59 loc) · 1.65 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
defmodule Engine.MixProject do
use Mix.Project
Code.require_file("../../mix_includes.exs")
def project do
[
app: :engine,
version: version(),
elixir: "~> 1.15",
start_permanent: Mix.env() == :prod,
deps: deps(),
dialyzer: Mix.Dialyzer.config(),
elixirc_paths: elixirc_paths(Mix.env()),
aliases: aliases(),
preferred_cli_env: [benchmark: :test]
]
end
def version do
"../../version.txt" |> File.read!() |> String.trim()
end
def application do
[
extra_applications: [:logger, :sasl, :eex, :path_glob],
mod: {Engine.Application, []}
]
end
# cli/0 is new for elixir 1.15, prior, we need to set `preferred_cli_env` in the project
def cli do
[
preferred_envs: [benchmark: :test]
]
end
defp elixirc_paths(:test) do
~w(lib test/support)
end
defp elixirc_paths(_) do
~w(lib)
end
defp deps do
[
{:deps_nix, "~> 2.4", only: :dev},
Mix.Credo.dependency(),
Mix.Dialyzer.dependency(),
{:elixir_sense,
github: "elixir-lsp/elixir_sense", ref: "e3ddc403554050221a2fd19a10a896fa7525bc02"},
{:forge, path: "../forge"},
{:gen_lsp, github: "Draggu/gen_lsp", branch: "exit"},
{:patch, "~> 0.15", only: [:dev, :test], runtime: false},
{:quokka, "~> 2.12", only: [:dev, :test], runtime: false},
{:path_glob, "~> 0.2"},
{:phoenix_live_view, "~> 1.0", only: [:test], runtime: false},
{:sourceror, "~> 1.10.1"},
{:stream_data, "~> 1.1", only: [:test], runtime: false},
{:refactorex, "~> 0.1.52"}
]
end
defp aliases do
[test: "test --no-start", benchmark: "run"]
end
end