forked from elixir-sqlite/exqlite
-
Notifications
You must be signed in to change notification settings - Fork 1
/
mix.exs
115 lines (101 loc) · 2.61 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
defmodule Exqlite.MixProject do
use Mix.Project
@version "0.11.3"
@sqlite_version "3.39.2"
def project do
[
app: :exqlite,
version: @version,
elixir: "~> 1.10",
compilers: [:elixir_make] ++ Mix.compilers(),
make_targets: ["all"],
make_clean: ["clean"],
start_permanent: Mix.env() == :prod,
aliases: aliases(),
deps: deps(),
package: package(),
description: description(),
test_paths: test_paths(System.get_env("EXQLITE_INTEGRATION")),
elixirc_paths: elixirc_paths(Mix.env()),
dialyzer: dialyzer(),
# Docs
name: "Exqlite",
source_url: "https://github.com/elixir-sqlite/exqlite",
homepage_url: "https://github.com/elixir-sqlite/exqlite",
docs: docs()
]
end
# Run "mix help compile.app" to learn about applications.
def application do
[
extra_applications: [:logger]
]
end
def sqlite_version, do: @sqlite_version
# Run "mix help deps" to learn about dependencies.
defp deps do
[
{:db_connection, "~> 2.1"},
{:ex_sqlean, "~> 0.8.5", only: [:dev, :test]},
{:elixir_make, "~> 0.6", runtime: false},
{:ex_doc, "~> 0.27", only: :dev, runtime: false},
{:temp, "~> 0.4", only: [:dev, :test]},
{:credo, "~> 1.6", only: [:dev, :test], runtime: false},
{:dialyxir, "~> 1.1.0", only: [:dev, :test], runtime: false},
{:table, "~> 0.1.0", optional: true}
]
end
defp aliases do
[
lint: ["format --check-formatted", "credo --all", "dialyzer"]
]
end
defp description do
"An Elixir SQLite3 library"
end
defp package do
[
files: ~w(
lib
.formatter.exs
mix.exs
README.md
LICENSE
.clang-format
c_src
Makefile*
),
name: "exqlite",
licenses: ["MIT"],
links: %{
"GitHub" => "https://github.com/elixir-sqlite/exqlite",
"Changelog" => "https://github.com/elixir-sqlite/exqlite/blob/main/CHANGELOG.md"
}
]
end
defp docs do
[
main: "readme",
extras: docs_extras(),
source_ref: "v#{@version}",
source_url: "https://github.com/elixir-sqlite/exqlite"
]
end
defp docs_extras do
[
"README.md": [title: "Readme"],
"guides/windows.md": [],
"CHANGELOG.md": []
]
end
defp elixirc_paths(:test), do: ["lib", "test/support"]
defp elixirc_paths(_), do: ["lib"]
defp test_paths(nil), do: ["test"]
defp test_paths(_any), do: ["integration_test/exqlite"]
defp dialyzer do
[
plt_add_deps: :apps_direct,
plt_add_apps: ~w(table)a
]
end
end