/
mix.exs
89 lines (80 loc) 路 2.06 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
defmodule MintWebSocket.MixProject do
use Mix.Project
@source_url "https://github.com/elixir-mint/mint_web_socket"
def project do
[
app: :mint_web_socket,
version: "1.0.3",
elixir: "~> 1.6",
elixirc_paths: elixirc_paths(Mix.env()),
erlc_paths: erlc_paths(Mix.env()),
start_permanent: Mix.env() == :prod,
deps: deps(),
test_coverage: [tool: ExCoveralls],
preferred_cli_env: [
coveralls: :test,
"coveralls.html": :test,
"coveralls.github": :test,
docs: :dev
],
dialyzer: [
plt_local_path: "priv/plts",
plt_add_apps: [:mix]
],
package: package(),
description: description(),
source_url: @source_url,
name: "MintWebSocket",
docs: docs()
]
end
def application do
[
extra_applications: [:logger]
]
end
defp deps do
[
{:mint, "~> 1.4 and >= 1.4.1"},
{:ex_doc, "~> 0.24", only: [:dev], runtime: false},
{:castore, ">= 0.0.0", only: [:dev]},
{:jason, ">= 0.0.0", only: [:dev, :test]},
{:cowboy, "~> 2.9", only: [:test]},
{:gun, "== 2.0.0-rc.2", only: [:test]},
{:excoveralls, "~> 0.14", only: [:test]},
{:dialyxir, "~> 1.2", only: [:dev, :test], runtime: false}
]
end
defp elixirc_paths(:test), do: ["lib", "test/fixtures"]
defp elixirc_paths(_), do: ["lib"]
defp erlc_paths(:test), do: ["src", "test/compare"]
defp erlc_paths(_), do: ["src"]
defp package do
[
name: "mint_web_socket",
files: ~w(lib .formatter.exs mix.exs README.md),
licenses: ["Apache-2.0"],
links: %{
"GitHub" => @source_url,
"Changelog" => @source_url <> "/blob/main/CHANGELOG.md"
}
]
end
defp description do
"HTTP/1 and HTTP/2 WebSocket support for Mint"
end
defp docs do
[
deps: [],
language: "en",
formatters: ["html"],
main: Mint.WebSocket,
extras: [
"CHANGELOG.md"
],
skip_undefined_reference_warnings_on: [
"CHANGELOG.md"
]
]
end
end