-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathmix.exs
93 lines (81 loc) · 1.96 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
defmodule SuperCache.MixProject do
use Mix.Project
def project do
[
app: :super_cache,
version: "0.6.1",
elixir: "~> 1.14",
start_permanent: Mix.env() == :prod,
deps: deps(),
config_path: "config/config.exs",
# Docs
name: "SuperCache",
source_url: "https://github.com/ohhi-vn/super_cache",
homepage_url: "https://ohhi.vn",
docs: docs(),
description: description(),
package: package()
]
end
# Run "mix help compile.app" to learn about applications.
def application do
dev_app =
if Mix.env() == :dev do
[:observer, :wx]
else
[]
end
[
mod: {SuperCache.Application, []},
extra_applications: [:logger] ++ dev_app
]
end
# Run "mix help deps" to learn about dependencies.
defp deps do
[
# {:swarm, "~> 3.4"},
{:ex_doc, "~> 0.36", only: :dev, runtime: false},
{:benchee, "~> 1.3", only: :dev},
]
end
defp description() do
"A library for cache data in memory. The library uses partition storage for a can cache service a mount of request. We are still developing please don't use for product."
end
defp package() do
[
maintainers: ["Manh Van Vu", "Tam Nhat Ly"],
licenses: ["MIT"],
links: %{"GitHub" => "https://github.com/ohhi-vn/super_cache", "About us" => "https://ohhi.vn/team"}
]
end
defp docs do
[
main: "readme",
extras: extras()
]
end
defp extras do
list =
"guides/**/*.md"
|> Path.wildcard()
list = list ++ ["README.md"]
list
|> Enum.map(fn path ->
title =
path
|> Path.basename(".md")
|> String.split(~r|[-_]|)
|> Enum.map_join(" ", &String.capitalize/1)
|> case do
"F A Q" ->"FAQ"
no_change -> no_change
end
{String.to_atom(path),
[
title: title,
default: title == "Guide"
]
}
end)
end
end