-
Notifications
You must be signed in to change notification settings - Fork 97
/
mix.exs
71 lines (63 loc) · 1.76 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
defmodule NewRelic.Mixfile do
use Mix.Project
@source_url "https://github.com/newrelic/elixir_agent"
def project do
[
app: :new_relic_agent,
description: "New Relic's Open-Source Elixir Agent",
version: agent_version(),
elixir: "~> 1.9",
build_embedded: Mix.env() == :prod,
start_permanent: Mix.env() == :prod,
name: "New Relic Elixir Agent",
source_url: @source_url,
elixirc_paths: elixirc_paths(Mix.env()),
package: package(),
deps: deps(),
docs: docs()
]
end
def application do
[
extra_applications: [:logger, :inets, :ssl, :os_mon],
mod: {NewRelic.Application, []}
]
end
defp package do
[
files: ["lib", "mix.exs", "README.md", "CHANGELOG.md", "VERSION"],
maintainers: ["Vince Foley"],
licenses: ["Apache-2.0"],
links: %{
"Changelog" => "#{@source_url}/blob/master/CHANGELOG.md",
"GitHub" => @source_url
}
]
end
defp deps do
[
{:ex_doc, ">= 0.0.0", only: :dev},
{:castore, ">= 0.1.0"},
{:jason, "~> 1.0"},
{:telemetry, "~> 0.4 or ~> 1.0"},
# Instrumentation:
{:plug, ">= 1.10.4", optional: true},
{:plug_cowboy, ">= 2.4.0", optional: true},
{:phoenix, ">= 1.5.5", optional: true},
{:ecto_sql, ">= 3.4.0", optional: true},
{:ecto, ">= 3.9.5", optional: true},
{:redix, ">= 0.11.0", optional: true}
]
end
defp docs do
[
main: "readme",
source_ref: "v" <> agent_version(),
extras: ["README.md", "CHANGELOG.md"]
]
end
defp elixirc_paths(:test), do: ["lib", "test/support"]
defp elixirc_paths(_), do: ["lib"]
@agent_version File.read!("VERSION") |> String.trim()
def agent_version, do: @agent_version
end