2019-10-03 16:08:36 +13:00
|
|
|
defmodule Ash.MixProject do
|
2020-06-02 17:51:13 +12:00
|
|
|
@moduledoc false
|
2019-10-03 16:08:36 +13:00
|
|
|
use Mix.Project
|
|
|
|
|
2019-12-05 04:18:00 +13:00
|
|
|
@description """
|
|
|
|
A resource declaration and interaction library. Built with pluggable data layers, and
|
|
|
|
designed to be used by multiple front ends.
|
|
|
|
"""
|
|
|
|
|
2021-07-28 15:04:33 +12:00
|
|
|
@version "1.47.5"
|
2020-06-01 17:23:33 +12:00
|
|
|
|
2019-10-03 16:08:36 +13:00
|
|
|
def project do
|
|
|
|
[
|
|
|
|
app: :ash,
|
2020-06-01 17:23:33 +12:00
|
|
|
version: @version,
|
2021-01-22 09:36:49 +13:00
|
|
|
elixir: "~> 1.11",
|
2021-01-07 08:39:56 +13:00
|
|
|
consolidate_protocols: Mix.env() != :test,
|
2019-10-03 16:08:36 +13:00
|
|
|
start_permanent: Mix.env() == :prod,
|
2019-11-28 18:24:29 +13:00
|
|
|
elixirc_paths: elixirc_paths(Mix.env()),
|
2019-12-05 04:16:34 +13:00
|
|
|
package: package(),
|
|
|
|
deps: deps(),
|
2020-06-30 09:42:01 +12:00
|
|
|
dialyzer: [plt_add_apps: [:mix, :mnesia]],
|
2020-06-03 00:52:41 +12:00
|
|
|
test_coverage: [tool: ExCoveralls],
|
|
|
|
preferred_cli_env: [
|
|
|
|
coveralls: :test,
|
2021-01-24 16:28:56 +13:00
|
|
|
"coveralls.github": :test,
|
|
|
|
"coveralls.html": :test
|
2020-06-03 00:52:41 +12:00
|
|
|
],
|
2020-10-21 06:11:21 +13:00
|
|
|
xref: [exclude: [:mnesia]],
|
2019-12-06 07:45:02 +13:00
|
|
|
docs: docs(),
|
2020-06-02 15:37:50 +12:00
|
|
|
aliases: aliases(),
|
2019-12-05 04:18:00 +13:00
|
|
|
description: @description,
|
2019-12-05 04:16:34 +13:00
|
|
|
source_url: "https://github.com/ash-project/ash",
|
|
|
|
homepage_url: "https://github.com/ash-project/ash"
|
|
|
|
]
|
|
|
|
end
|
|
|
|
|
2020-06-02 17:51:13 +12:00
|
|
|
defp docs do
|
2019-12-06 07:45:02 +13:00
|
|
|
# The main page in the docs
|
2020-06-14 18:39:11 +12:00
|
|
|
[
|
2020-10-10 03:13:44 +13:00
|
|
|
main: "readme",
|
2020-06-14 18:39:11 +12:00
|
|
|
source_ref: "v#{@version}",
|
|
|
|
logo: "logos/small-logo.png",
|
2020-07-10 01:25:48 +12:00
|
|
|
extra_section: "GUIDES",
|
2020-07-15 17:38:42 +12:00
|
|
|
extras: [
|
2020-11-28 16:06:13 +13:00
|
|
|
"README.md": [],
|
|
|
|
"documentation/introduction/getting_started.md": [
|
|
|
|
title: "Getting Started"
|
|
|
|
],
|
|
|
|
"documentation/introduction/getting_started_phx.md": [
|
|
|
|
title: "Getting Started with Phoenix"
|
|
|
|
],
|
2021-07-02 14:55:07 +12:00
|
|
|
"documentation/topics/expressions.md": [
|
|
|
|
title: "Expressions"
|
|
|
|
],
|
2021-04-06 05:45:39 +12:00
|
|
|
"documentation/topics/managing_relationships.md": [
|
|
|
|
title: "Managing Relationships"
|
|
|
|
],
|
2021-01-13 09:25:59 +13:00
|
|
|
"documentation/topics/authorization.md": [
|
|
|
|
title: "Authorization"
|
|
|
|
],
|
|
|
|
"documentation/topics/identities.md": [
|
|
|
|
title: "Identities"
|
|
|
|
],
|
|
|
|
"documentation/topics/pagination.md": [
|
|
|
|
title: "Pagination"
|
|
|
|
],
|
|
|
|
"documentation/topics/validation.md": [
|
|
|
|
title: "Validation"
|
|
|
|
],
|
|
|
|
"documentation/topics/notifiers.md": [
|
|
|
|
title: "Notifiers"
|
|
|
|
],
|
|
|
|
"documentation/topics/error_handling.md": [
|
|
|
|
title: "Error Handling"
|
|
|
|
],
|
|
|
|
"documentation/topics/aggregates.md": [
|
|
|
|
title: "Aggregates"
|
|
|
|
],
|
|
|
|
"documentation/topics/calculations.md": [
|
|
|
|
title: "Calculations"
|
|
|
|
],
|
|
|
|
"documentation/topics/embedded_resources.md": [
|
|
|
|
title: "Embedded Resources"
|
|
|
|
],
|
|
|
|
"documentation/topics/contexts_and_domains.md": [
|
|
|
|
title: "Context And Domains"
|
|
|
|
],
|
|
|
|
"documentation/topics/multitenancy.md": [
|
|
|
|
title: "Multitenancy"
|
|
|
|
]
|
2020-07-15 17:38:42 +12:00
|
|
|
],
|
2020-07-10 01:25:48 +12:00
|
|
|
groups_for_extras: [
|
2020-07-15 17:38:42 +12:00
|
|
|
Introduction: Path.wildcard("documentation/introduction/*.md"),
|
2020-07-16 13:17:57 +12:00
|
|
|
Topics: Path.wildcard("documentation/topics/*")
|
2020-07-10 01:25:48 +12:00
|
|
|
],
|
2020-06-14 18:39:11 +12:00
|
|
|
groups_for_modules: [
|
|
|
|
entrypoint: [
|
|
|
|
Ash,
|
|
|
|
Ash.Api,
|
2020-07-12 18:25:53 +12:00
|
|
|
Ash.Query,
|
2020-10-12 16:55:47 +13:00
|
|
|
Ash.Changeset,
|
|
|
|
Ash.Resource.Dsl,
|
|
|
|
Ash.Api.Dsl
|
2020-06-14 18:39:11 +12:00
|
|
|
],
|
2021-03-15 11:29:30 +13:00
|
|
|
tools: [
|
|
|
|
Ash.Filter,
|
|
|
|
Ash.Sort
|
|
|
|
],
|
2020-09-23 03:22:21 +12:00
|
|
|
validations: ~r/Ash.Resource.Validation/,
|
|
|
|
changes: ~r/Ash.Resource.Change/,
|
|
|
|
calculations: [
|
|
|
|
~r/Ash.Resource.Calculation/,
|
|
|
|
Ash.Query.Calculation,
|
|
|
|
Ash.Calculation
|
|
|
|
],
|
2021-01-29 08:47:59 +13:00
|
|
|
values: [
|
|
|
|
Ash.CiString
|
|
|
|
],
|
2020-06-14 18:39:11 +12:00
|
|
|
type: ~r/Ash.Type/,
|
|
|
|
data_layer: ~r/Ash.DataLayer/,
|
|
|
|
authorizer: ~r/Ash.Authorizer/,
|
2020-10-12 16:55:47 +13:00
|
|
|
pagination: ~r/Ash.Page/,
|
2020-10-15 17:54:02 +13:00
|
|
|
notifications: ~r/Ash.Notifier/,
|
2020-06-14 18:39:11 +12:00
|
|
|
extension: [
|
|
|
|
Ash.Dsl.Entity,
|
|
|
|
Ash.Dsl.Extension,
|
2020-08-10 19:51:28 +12:00
|
|
|
Ash.Dsl.Section,
|
|
|
|
Ash.Dsl.Transformer
|
2020-06-14 18:39:11 +12:00
|
|
|
],
|
2021-01-14 19:17:26 +13:00
|
|
|
"dsl tooling": [
|
|
|
|
Ash.Dsl
|
|
|
|
],
|
2020-06-14 18:39:11 +12:00
|
|
|
"resource dsl transformers": ~r/Ash.Resource.Transformers/,
|
2020-06-29 15:43:35 +12:00
|
|
|
"api dsl transformers": ~r/Ash.Api.Transformers/,
|
2020-10-06 17:58:06 +13:00
|
|
|
"filter operators": ~r/Ash.Query.Operator/,
|
|
|
|
"filter functions": ~r/Ash.Query.Function/,
|
2020-10-07 18:20:03 +13:00
|
|
|
"query expressions": [
|
2021-01-29 08:47:59 +13:00
|
|
|
Ash.Query.BooleanExpression,
|
2020-10-07 18:20:03 +13:00
|
|
|
Ash.Query.Not,
|
2021-01-22 09:21:58 +13:00
|
|
|
Ash.Query.Ref,
|
|
|
|
Ash.Query.Call
|
2020-10-07 18:20:03 +13:00
|
|
|
],
|
2020-07-12 18:25:53 +12:00
|
|
|
filter: ~r/Ash.Filter/,
|
|
|
|
"resource introspection": ~r/Ash.Resource/,
|
2020-08-10 19:51:28 +12:00
|
|
|
"api introspection": ~r/Ash.Api/,
|
2020-09-25 16:36:50 +12:00
|
|
|
engine: [
|
|
|
|
~r/Ash.Engine/
|
|
|
|
],
|
2021-02-23 14:57:27 +13:00
|
|
|
errors: [
|
2021-03-20 11:23:48 +13:00
|
|
|
Ash.Error,
|
2021-02-23 14:57:27 +13:00
|
|
|
Ash.Error.Stacktrace,
|
|
|
|
Ash.Error.Exception
|
|
|
|
],
|
2020-08-10 19:51:28 +12:00
|
|
|
miscellaneous: [
|
2021-02-23 14:57:27 +13:00
|
|
|
Ash.UUID,
|
2021-03-26 04:35:26 +13:00
|
|
|
Ash.Changeset.ManagedRelationshipHelpers,
|
2020-08-10 19:51:28 +12:00
|
|
|
Ash.NotLoaded,
|
2021-01-29 08:47:59 +13:00
|
|
|
Ash.Query.Aggregate,
|
2021-03-15 11:29:30 +13:00
|
|
|
Ash.Query.Type,
|
2021-03-20 10:07:22 +13:00
|
|
|
Ash.SatSolver,
|
|
|
|
Ash.OptionsHelpers
|
2021-01-29 08:47:59 +13:00
|
|
|
],
|
|
|
|
comparable: ~r/Comparable/
|
2020-06-14 18:39:11 +12:00
|
|
|
]
|
|
|
|
]
|
2019-12-06 07:45:02 +13:00
|
|
|
end
|
|
|
|
|
2019-12-05 04:16:34 +13:00
|
|
|
defp package do
|
|
|
|
[
|
2020-07-21 14:16:28 +12:00
|
|
|
name: :ash,
|
2019-12-05 04:16:34 +13:00
|
|
|
licenses: ["MIT"],
|
|
|
|
links: %{
|
|
|
|
GitHub: "https://github.com/ash-project/ash"
|
|
|
|
}
|
2019-10-03 16:08:36 +13:00
|
|
|
]
|
|
|
|
end
|
|
|
|
|
2019-11-28 18:24:29 +13:00
|
|
|
defp elixirc_paths(:test) do
|
|
|
|
["lib", "test/support"]
|
|
|
|
end
|
|
|
|
|
2019-11-29 19:54:11 +13:00
|
|
|
defp elixirc_paths(_), do: ["lib"]
|
2019-11-28 18:24:29 +13:00
|
|
|
|
2019-10-03 16:08:36 +13:00
|
|
|
# Run "mix help deps" to learn about dependencies.
|
|
|
|
defp deps do
|
2019-11-28 18:24:29 +13:00
|
|
|
[
|
2020-06-14 18:39:11 +12:00
|
|
|
{:ecto, "~> 3.4"},
|
2019-12-07 09:54:30 +13:00
|
|
|
{:ets, "~> 0.8.0"},
|
2021-01-10 05:47:50 +13:00
|
|
|
{:decimal, "~> 2.0"},
|
|
|
|
{:picosat_elixir, "~> 0.1.5"},
|
|
|
|
{:nimble_options, "~> 0.3.5"},
|
2021-01-22 09:21:58 +13:00
|
|
|
{:timex, ">= 3.0.0"},
|
|
|
|
{:comparable, "~> 1.0"},
|
2021-01-23 12:20:08 +13:00
|
|
|
{:jason, ">= 1.0.0"},
|
2021-01-10 05:47:50 +13:00
|
|
|
# Dev/Test dependencies
|
2020-06-14 18:39:11 +12:00
|
|
|
{:ex_doc, "~> 0.22", only: :dev, runtime: false},
|
2020-08-21 13:28:25 +12:00
|
|
|
{:ex_check, "~> 0.12.0", only: :dev},
|
2020-06-02 13:22:08 +12:00
|
|
|
{:credo, ">= 0.0.0", only: :dev, runtime: false},
|
|
|
|
{:dialyxir, ">= 0.0.0", only: :dev, runtime: false},
|
|
|
|
{:sobelow, ">= 0.0.0", only: :dev, runtime: false},
|
2021-06-25 06:45:20 +12:00
|
|
|
{:git_ops, "~> 2.4.4", only: :dev},
|
2020-08-21 13:27:32 +12:00
|
|
|
{:excoveralls, "~> 0.13.0", only: [:dev, :test]},
|
2020-10-06 17:58:06 +13:00
|
|
|
{:mix_test_watch, "~> 1.0", only: :dev, runtime: false},
|
|
|
|
{:parse_trans, "3.3.0", only: [:dev, :test], override: true}
|
2019-11-28 18:24:29 +13:00
|
|
|
]
|
2019-10-03 16:08:36 +13:00
|
|
|
end
|
2020-06-02 15:37:50 +12:00
|
|
|
|
2020-06-02 17:47:25 +12:00
|
|
|
defp aliases do
|
|
|
|
[
|
|
|
|
sobelow: "sobelow --skip",
|
2020-06-15 18:40:33 +12:00
|
|
|
credo: "credo --strict",
|
2020-06-30 09:20:29 +12:00
|
|
|
"ash.formatter":
|
2020-10-18 06:06:27 +13:00
|
|
|
"ash.formatter --extensions Ash.Resource.Dsl,Ash.Api.Dsl,Ash.DataLayer.Ets,Ash.DataLayer.Mnesia,Ash.Notifier.PubSub"
|
2020-06-02 17:47:25 +12:00
|
|
|
]
|
2020-06-02 15:37:50 +12:00
|
|
|
end
|
2019-10-03 16:08:36 +13:00
|
|
|
end
|