forked from hexpm/hexpm
-
Notifications
You must be signed in to change notification settings - Fork 0
/
mix.exs
96 lines (88 loc) · 2.31 KB
/
mix.exs
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
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
defmodule Hexpm.MixProject do
use Mix.Project
def project() do
[
app: :hexpm,
version: "0.0.1",
elixir: "~> 1.10",
elixirc_paths: elixirc_paths(Mix.env()),
xref: xref(),
compilers: [:phoenix] ++ Mix.compilers(),
build_embedded: Mix.env() == :prod,
start_permanent: Mix.env() == :prod,
aliases: aliases(),
releases: releases(),
deps: deps()
]
end
def application() do
[
mod: {Hexpm.Application, []},
extra_applications: [:logger, :runtime_tools, :os_mon]
]
end
defp elixirc_paths(:test), do: ["lib", "test/support"]
defp elixirc_paths(_), do: ["lib"]
defp xref() do
[exclude: [Hex.Registry, Hex.Resolver]]
end
defp deps() do
[
{:bamboo, "~> 1.0"},
{:bcrypt_elixir, "~> 2.0"},
{:corsica, "~> 1.0"},
{:earmark, "~> 1.0"},
{:ecto_sql, "~> 3.0"},
{:ecto, "~> 3.0", override: true},
{:ex_aws_s3, "~> 2.0"},
{:ex_aws_ses, "~> 2.0"},
{:ex_aws, "~> 2.0"},
{:ex_machina, "~> 2.0"},
{:eqrcode, "~> 0.1.6"},
{:goth, "~> 1.2"},
{:hackney, "~> 1.7"},
{:hex_core, "~> 0.2", hex_core_opts()},
{:jason, "~> 1.0"},
{:libcluster, "~> 3.0"},
{:logster, "~> 1.0.0"},
{:mox, "~> 0.5.0", only: :test},
{:phoenix_ecto, "~> 4.0"},
{:phoenix_html, "~> 2.3"},
{:phoenix_live_dashboard, "~> 0.1"},
{:phoenix_live_reload, "~> 1.0", only: :dev},
{:phoenix_pubsub, "~> 2.0"},
{:phoenix, "~> 1.5"},
{:plug_attack, "~> 0.3"},
{:plug_cowboy, "~> 2.1"},
{:plug, "~> 1.7"},
{:postgrex, "~> 0.14"},
{:pot, "~> 0.11.0"},
{:rollbax, "~> 0.5"},
{:sweet_xml, "~> 0.5"},
{:telemetry_poller, "~> 0.4"},
{:telemetry_metrics, "~> 0.4"}
]
end
defp hex_core_opts() do
if path = System.get_env("HEX_CORE_PATH") do
[path: path]
else
[]
end
end
defp aliases() do
[
setup: ["deps.get", "ecto.setup", "cmd yarn install --cwd assets"],
"ecto.setup": ["ecto.reset", "run priv/repo/seeds.exs"],
"ecto.reset": ["ecto.drop", "ecto.create", "ecto.migrate"],
test: ["ecto.create --quiet", "ecto.migrate", "test"]
]
end
defp releases() do
[
hexpm: [
include_executables_for: [:unix]
]
]
end
end