-
Notifications
You must be signed in to change notification settings - Fork 4
/
mix.exs
94 lines (82 loc) · 2 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
defmodule Correios.CEP.MixProject do
use Mix.Project
@app :correios_cep
@name "Correios CEP"
@repo "https://github.com/prodis/correios-cep-elixir"
@version "0.7.0"
def project do
[
app: @app,
name: @name,
version: @version,
elixir: "~> 1.7",
elixirc_paths: elixirc_paths(Mix.env()),
start_permanent: Mix.env() == :prod,
deps: deps(),
dialyzer: dialyzer(),
description: description(),
package: package(),
docs: docs(),
test_coverage: [tool: ExCoveralls],
preferred_cli_env: preferred_cli_env()
]
end
def application do
[
extra_applications: [:logger]
]
end
defp deps do
[
# Common
{:httpoison, "~> 1.7"},
{:sweet_xml, "~> 0.6"},
# Development
{:credo, "~> 1.3", only: :dev, runtime: false},
{:dialyxir, "~> 1.0", only: :dev, runtime: false},
{:ex_doc, "~> 0.21", only: :dev, runtime: false},
# Test
{:bypass, "~> 1.0", only: :test},
{:excoveralls, "~> 0.13", only: :test}
]
end
defp description do
"""
Find Brazilian addresses by postal code, directly from Correios API. No HTML parsers.
"""
end
defp dialyzer do
[
plt_file: {:no_warn, "priv/plts/dialyzer.plt"}
]
end
defp package do
[
files: ~w(lib mix.exs README.md CHANGELOG.md LICENSE),
maintainers: ["Fernando Hamasaki de Amorim"],
licenses: ["Apache 2.0"],
links: %{"GitHub" => @repo}
]
end
defp docs() do
[
main: "readme",
extras: ~w(README.md CHANGELOG.md),
formatters: ["html"],
source_ref: @version,
source_url: @repo,
canonical: "http://hexdocs.pm/correios_cep"
]
end
defp elixirc_paths(:test), do: ["lib", "test/support"]
defp elixirc_paths(_), do: ["lib"]
defp preferred_cli_env do
[
coveralls: :test,
"coveralls.detail": :test,
"coveralls.post": :test,
"coveralls.html": :test,
"coveralls.travis": :test
]
end
end