-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathmix.exs
More file actions
129 lines (112 loc) · 3.33 KB
/
mix.exs
File metadata and controls
129 lines (112 loc) · 3.33 KB
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
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
defmodule DurableStreams.MixProject do
use Mix.Project
@version "0.3.0"
@source_url "https://github.com/errantsky/streamkeeper"
def project do
[
app: :streamkeeper,
version: @version,
elixir: "~> 1.19",
start_permanent: Mix.env() == :prod,
deps: deps(),
# Hex.pm
description:
"Streamkeeper - an Elixir/OTP implementation of the Durable Streams protocol for append-only, URL-addressable byte logs with long-polling and SSE support",
package: package(),
# Docs
name: "Streamkeeper",
source_url: @source_url,
docs: docs(),
# Testing
elixirc_paths: elixirc_paths(Mix.env()),
# Dialyzer
dialyzer: dialyzer()
]
end
def application do
[
extra_applications: [:logger],
mod: {DurableStreams.Application, []}
]
end
defp deps do
[
# Required dependencies (included in published package)
{:plug, "~> 1.15"},
{:phoenix_pubsub, "~> 2.1"},
# Optional HTTP server adapters - users choose one
{:plug_cowboy, "~> 2.7", optional: true},
{:bandit, "~> 1.6", optional: true},
# Optional Phoenix LiveView integration
{:phoenix_live_view, "~> 1.0", optional: true},
# Development and test dependencies (not included in published package)
{:jason, "~> 1.4", only: [:dev, :test]},
{:ex_doc, "~> 0.34", only: :dev, runtime: false},
{:credo, "~> 1.7", only: [:dev, :test], runtime: false},
{:sobelow, "~> 0.13", only: [:dev, :test], runtime: false},
{:stream_data, "~> 1.1", only: [:dev, :test], runtime: false},
# Benchmarking
{:benchee, "~> 1.3", only: :dev},
{:benchee_html, "~> 1.0", only: :dev},
{:benchee_markdown, "~> 0.3", only: :dev},
# Static analysis
{:dialyxir, "~> 1.4", only: [:dev, :test], runtime: false}
]
end
defp package do
[
maintainers: ["errantsky"],
licenses: ["MIT"],
links: %{"GitHub" => @source_url},
files: ~w(lib .formatter.exs mix.exs README.md LICENSE)
]
end
defp docs do
[
main: "readme",
extras: ["README.md", "CHANGELOG.md", "LICENSE"],
source_ref: "v#{@version}",
groups_for_modules: [
"Core API": [
DurableStreams,
DurableStreams.StreamManager
],
"HTTP Integration": [
DurableStreams.Protocol.Plug
],
"Phoenix LiveView": [
DurableStreams.LiveView
],
"Data Types": [
DurableStreams.Stream,
DurableStreams.Offset
],
Storage: [
DurableStreams.Storage.Behaviour,
DurableStreams.Storage.ETS
],
Internals: [
DurableStreams.Server.StreamServer,
DurableStreams.Protocol.Handlers.Create,
DurableStreams.Protocol.Handlers.Append,
DurableStreams.Protocol.Handlers.Read,
DurableStreams.Protocol.Handlers.Delete,
DurableStreams.Protocol.Handlers.Head,
DurableStreams.Protocol.Handlers.SSE
]
],
nest_modules_by_prefix: [
DurableStreams.Protocol,
DurableStreams.Storage,
DurableStreams.Server
]
]
end
defp elixirc_paths(:test), do: ["lib", "test/support"]
defp elixirc_paths(_), do: ["lib"]
defp dialyzer do
[
plt_add_apps: [:mix]
]
end
end