This repository has been archived by the owner on Nov 8, 2022. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 21
/
Copy pathmix.exs
142 lines (136 loc) · 4.14 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
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
130
131
132
133
134
135
136
137
138
139
140
141
142
defmodule GroupherServer.Mixfile do
@moduledoc false
use Mix.Project
def project do
[
app: :groupher_server,
version: "2.1.0",
elixir: "~> 1.9",
elixirc_paths: elixirc_paths(Mix.env()),
compilers: [:phoenix, :gettext] ++ Mix.compilers(),
dialyzer: [plt_add_deps: :transitive, ignore_warnings: ".dialyzer_ignore.exs"],
test_coverage: [tool: ExCoveralls],
preferred_cli_env: [
coveralls: :test,
"coveralls.detail": :test,
"coveralls.post": :test,
"coveralls.html": :test
],
start_permanent: Mix.env() == :prod,
aliases: aliases(),
deps: deps()
]
end
# Configuration for the OTP application.
#
# Type `mix help compile.app` for more information.
def application do
[
mod: {GroupherServer.Application, []},
extra_applications: [
:open_graph,
:corsica,
:ex_unit,
:logger,
:runtime_tools,
:faker,
:scrivener_ecto,
:timex,
:sentry
]
]
end
# Specifies which paths to compile per environment.
defp elixirc_paths(:test), do: ["lib", "test/support"]
defp elixirc_paths(:mock), do: ["lib", "priv/mock", "test/support"]
defp elixirc_paths(_), do: ["lib", "test/support"]
# Specifies your project dependencies.
#
# Type `mix help deps` for examples and options.
defp deps do
[
{:phoenix, "~> 1.5.7"},
{:phoenix_pubsub, "~> 2.0"},
{:phoenix_html, "~> 2.14.3"},
{:ecto_sql, "~> 3.6.1"},
{:phoenix_ecto, "~> 4.2.1"},
{:postgrex, "~> 0.15.8"},
{:gettext, "~> 0.18.0"},
{:plug_cowboy, "~> 2.5.0"},
{:plug, "~> 1.11.0"},
# GraphQl tool
{:absinthe, "~> 1.6.2"},
# Plug support for Absinthe
{:absinthe_plug, "~> 1.5.4"},
# Password hashing lib
{:comeonin, "~> 5.3.2"},
# CORS
{:corsica, "~> 1.1.2"},
{:tesla, "~> 1.4"},
# optional, but recommended adapter
{:hackney, "~> 1.8"},
# only used for tesla's JSON-encoder
{:poison, "~> 3.1"},
# for fake data in test env
{:faker, "~> 0.17.0"},
{:scrivener_ecto, "~> 2.7.0"},
# enhanced cursor based pagination
{:quarto, "~> 1.1.5"},
{:guardian, "~> 2.0"},
{:timex, "~> 3.7.5"},
{:dataloader, "~> 1.0.7"},
{:mix_test_watch, "~> 1.0.2", only: :dev, runtime: false},
{:ex_unit_notifier, "~> 1.0", only: :test},
{:apollo_tracing, "~> 0.4.3"},
{:pre_commit, "~> 0.3.4"},
{:inch_ex, "~> 2.0", only: [:dev, :test]},
{:short_maps, "~> 0.1.1"},
{:jason, "~> 1.1.1"},
{:credo, "~> 1.5.5", only: [:dev, :test], runtime: false},
{:dialyxir, "~> 1.1.0", only: [:dev, :mock], runtime: false},
{:excoveralls, "~> 0.8", only: :test},
{:sentry, "~> 8.0"},
{:recase, "~> 0.7.0"},
{:nanoid, "~> 2.0.5"},
# mailer
{:bamboo, "1.3.0"},
# mem cache
{:cachex, "3.3.0"},
# postgres-backed job queue
{:rihanna, "1.3.5"},
# cron-like scheduler job
{:quantum, "~> 2.3"},
{:html_sanitize_ex, "~> 1.3"},
{:open_graph, "~> 0.0.3"},
{:earmark, "~> 1.4.13"},
# 遵循中文排版指南
# https://github.com/cataska/pangu.ex
{:pangu, "~> 0.1.0"},
{:accessible, "~> 0.3.0"},
{:floki, "~> 0.30.1"},
{:httpoison, "~> 1.8"},
# rss feed parser
{:fiet, "~> 0.3"}
]
end
# Aliases are shortcuts or tasks specific to the current project.
# For example, to create, migrate and run the seeds file at once:
#
# $ mix ecto.setup
#
# See the documentation for `Mix` for more info on aliases.
defp aliases do
[
"ecto.setup": ["ecto.create", "ecto.migrate"],
"ecto.reset": ["ecto.drop", "ecto.setup"],
test: ["ecto.create --quiet", "ecto.migrate", "test"],
"test.coverage": ["coveralls.html"],
"test.coverage.short": ["coveralls"],
"doc.report": ["inch.report"],
lint: ["credo --strict"],
"lint.static": ["dialyzer --format dialyxir"],
"cps.seeds": ["run priv/mock/cps_seeds.exs"],
sentry_recompile: ["compile", "deps.compile sentry --force"]
]
end
end