-
Notifications
You must be signed in to change notification settings - Fork 6
/
Copy pathmix.exs
78 lines (73 loc) · 2.09 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
defmodule Apical.MixProject do
use Mix.Project
def project do
[
app: :apical,
version: "0.2.1",
elixir: "~> 1.14",
start_permanent: Mix.env() == :prod,
elixirc_paths: elixirc_paths(Mix.env()),
package: [
description: "OpenAPI 3.1.0 router generator for Elixir",
licenses: ["MIT"],
files: ~w(lib mix.exs README* LICENSE* CHANGELOG*),
links: %{"GitHub" => "https://github.com/E-xyza/Apical"}
],
source_url: "https://github.com/E-xyza/Apical/",
deps: deps(),
docs: docs()
]
end
def application do
[
extra_applications: [:logger]
]
end
def elixirc_paths(:test), do: ["lib", "test/_support"]
def elixirc_paths(_), do: ["lib"]
defp deps do
[
{:pegasus, "~> 0.2.4", runtime: false},
{:exonerate, "~> 1.1.2", runtime: false},
{:bandit, ">= 0.7.6", only: :test},
# note that phoenix is an optional dependency.
{:phoenix, "~> 1.7.2", only: [:test, :dev], optional: true},
{:phoenix_html, "~> 3.3.1", only: :test, optional: true},
{:req, "~> 0.3.10", only: :test},
{:yaml_elixir, "~> 2.7", optional: true},
{:jason, "~> 1.4", optional: true},
{:mox, "~> 1.0", optional: true},
{:bypass, "~> 2.1", optional: true},
{:plug, "~> 1.14"},
{:json_ptr, "~> 1.2"},
{:ex_doc, "~> 0.27", only: :dev, runtime: false}
]
end
defp docs do
[
main: "Apical",
source_ref: "main",
extra_section: "GUIDES",
extras: ["guides/Apical for testing.md"],
groups_for_modules: [
Behaviours: [
Apical.Plugs.RequestBody.Source
],
Plugs: [
Apical.Plugs.Cookie,
Apical.Plugs.Header,
Apical.Plugs.Path,
Apical.Plugs.Query,
Apical.Plugs.RequestBody,
Apical.Plugs.SetOperationId,
Apical.Plugs.SetVersion
],
"RequestBody Source Plugins": [
Apical.Plugs.RequestBody.Default,
Apical.Plugs.RequestBody.Json,
Apical.Plugs.RequestBody.FormEncoded
]
]
]
end
end