77 lines
2.4 kB
1
defmodule Blog.MixProject do
2
use Mix.Project
3
4
def project do
5
[
6
app: :blog,
7
version: "0.1.0",
8
elixir: "~> 1.14",
9
elixirc_paths: elixirc_paths(Mix.env()),
10
start_permanent: Mix.env() == :prod,
11
aliases: aliases(),
12
deps: deps(),
13
compile_options: [:debug_info],
14
elixirc_options: [debug_info: true]
15
]
16
end
17
18
# Configuration for the OTP application.
19
#
20
# Type `mix help compile.app` for more information.
21
def application do
22
[
23
mod: {Blog.Application, []},
24
extra_applications: [:logger, :runtime_tools, :inet]
25
]
26
end
27
28
# Specifies which paths to compile per environment.
29
defp elixirc_paths(:test), do: ["lib", "test/support"]
30
defp elixirc_paths(_), do: ["lib"]
31
32
# Specifies your project dependencies.
33
#
34
# Type `mix help deps` for examples and options.
35
defp deps do
36
[
37
{:phoenix, "~> 1.7.10"},
38
{:phoenix_html, "~> 4.1"},
39
{:phoenix_live_reload, "~> 1.2", only: :dev},
40
{:phoenix_live_view, "~> 1.0.0"},
41
{:phoenix_pubsub, "~> 2.0"},
42
{:floki, ">= 0.30.0", only: :test},
43
{:req, "~> 0.5.0"},
44
{:phoenix_live_dashboard, "~> 0.8.3"},
45
{:esbuild, "~> 0.8", runtime: Mix.env() == :dev},
46
{:tailwind, "~> 0.2", runtime: Mix.env() == :dev},
47
{:swoosh, "~> 1.5"},
48
{:finch, "~> 0.13"},
49
{:telemetry_metrics, "~> 1.0"},
50
{:telemetry_poller, "~> 1.0"},
51
{:gettext, "~> 0.26"},
52
{:jason, "~> 1.2"},
53
{:bandit, "~> 1.5"},
54
{:earmark, "~> 1.4"},
55
{:websockex, "~> 0.4.3"},
56
{:pythonx, "~> 0.4.2"}
57
]
58
end
59
60
# Aliases are shortcuts or tasks specific to the current project.
61
# For example, to install project dependencies and perform other setup tasks, run:
62
#
63
# $ mix setup
64
#
65
# See the documentation for `Mix` for more info on aliases.
66
defp aliases do
67
[
68
setup: ["deps.get", "ecto.setup", "assets.setup", "assets.build"],
69
"ecto.setup": ["ecto.create", "ecto.migrate", "run priv/repo/seeds.exs"],
70
"ecto.reset": ["ecto.drop", "ecto.setup"],
71
test: ["ecto.create --quiet", "ecto.migrate --quiet", "test"],
72
"assets.setup": ["tailwind.install --if-missing", "esbuild.install --if-missing"],
73
"assets.build": ["tailwind blog", "esbuild blog"],
74
"assets.deploy": ["tailwind blog --minify", "esbuild blog --minify", "phx.digest"]
75
]
76
end
77
end
78