-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathmix.exs
88 lines (80 loc) · 2.33 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
defmodule Paradex.MixProject do
use Mix.Project
@name "Paradex"
@version "0.3.3"
@source_url "https://github.com/Moosieus/paradex"
def project do
[
app: :paradex,
name: @name,
description: "Ecto fragments for ParadeDB.",
source_url: @source_url,
homepage_url: @source_url,
version: @version,
elixir: "~> 1.13",
elixirc_paths: elixirc_paths(Mix.env()),
start_permanent: Mix.env() == :prod,
deps: deps(),
docs: docs(),
package: package(),
aliases: aliases()
]
end
defp elixirc_paths(:test), do: elixirc_paths(:dev) ++ ["test/support"]
defp elixirc_paths(_), do: ["lib"]
def package do
[
licenses: ["Apache-2.0"],
files: ["lib", "mix.exs", "README.md", "CHANGELOG.md", "LICENSE"],
links: %{"GitHub" => @source_url}
]
end
# Run "mix help compile.app" to learn about applications.
def application do
[
extra_applications: [:logger]
]
end
# Run "mix help deps" to learn about dependencies.
defp deps do
[
{:postgrex, ">= 0.0.0"},
{:pgvector, "~> 0.3.0", optional: true},
{:ecto, "~> 3.0", optional: true},
{:ecto_sql, "~> 3.0", only: :test},
{:jason, "~> 1.4", only: :test},
{:ex_doc, ">= 0.0.0", only: :dev, runtime: false},
{:dialyxir, "~> 1.0", only: [:dev, :test], runtime: false}
]
end
defp docs do
[
name: @name,
main: "readme",
source_ref: "v#{@version}",
source_url: @source_url,
extras: [
"README.md",
"CHANGELOG.md",
"notebooks/hybrid_search.livemd"
],
groups_for_docs: [
{:Macros, &(&1[:section] == :macros)},
{:"Term-level queries", &(&1[:section] == :term_level_queries)},
{:"Range queries", &(&1[:section] == :range_queries)},
{:"Phrase-level queries", &(&1[:section] == :phrase_level_queries)},
{:"Compound queries", &(&1[:section] == :compound_queries)},
{:"Specialized queries", &(&1[:section] == :specialized_queries)},
{:Functions, &(&1[:section] == nil)}
]
]
end
defp aliases do
[
setup: ["deps.get", "ecto.setup"],
"ecto.setup": ["ecto.create", "ecto.migrate"],
"ecto.reset": ["ecto.drop", "ecto.setup"],
test: ["ecto.create --quiet", "ecto.migrate --quiet", "test"]
]
end
end