smokestack/mix.exs

96 lines
2.5 KiB
Elixir
Raw Normal View History

2023-08-09 20:18:46 +12:00
defmodule Smokestack.MixProject do
use Mix.Project
2023-09-20 14:09:14 +12:00
@version "0.4.1"
2023-08-09 20:18:46 +12:00
@moduledoc """
Test factories for Ash resources.
"""
def project do
[
app: :smokestack,
version: @version,
elixir: "~> 1.15",
start_permanent: Mix.env() == :prod,
2023-08-10 21:01:45 +12:00
consolidate_protocols: Mix.env() != :test,
elixirc_paths: elixirc_paths(Mix.env()),
2023-08-09 20:18:46 +12:00
deps: deps(),
description: @moduledoc,
package: package(),
source_url: "https://code.harton.nz/james/smokestack",
homepage_url: "https://code.harton.nz/james/smokestack",
2023-08-10 21:01:45 +12:00
aliases: aliases(),
dialyzer: [plt_add_apps: [:faker]],
docs: [
main: "Smokestack",
extra_section: "GUIDES",
formatters: ["html"],
filter_modules: ~r/^Elixir.Smokestack/,
source_url_pattern:
"https://code.harton.nz/james/smokestack/src/branch/main/%{path}#L%{line}",
spark: [
extensions: [
%{
module: Smokestack.Dsl,
name: "Smokestack.Dsl",
target: "Smokestack",
type: "Smokestack"
}
]
]
]
2023-08-09 20:18:46 +12:00
]
end
def package do
[
name: :smokestack,
files: ~w[lib .formatter.exs mix.exs README* LICENSE* CHANGELOG* documentation],
2023-08-09 20:18:46 +12:00
maintainers: ["James Harton <james@harton.nz>"],
licenses: ["HL3-FULL"],
links: %{
"Source" => "https://code.harton.nz/james/smokestack",
"Github Mirror" => "https://github.com/jimsynz/smokestack"
},
source_url: "https://code.harton.nz/james/smokestack"
2023-08-09 20:18:46 +12:00
]
end
def application do
[
extra_applications: [:logger],
mod: {Smokestack.Application, []}
]
end
defp deps do
opts = [only: ~w[dev test]a, runtime: false]
[
{:ash, "~> 2.13"},
{:credo, "~> 1.7", opts},
{:dialyxir, "~> 1.3", opts},
{:doctor, "~> 0.21", opts},
{:earmark, ">= 0.0.0", opts},
{:ex_check, "~> 0.15", opts},
{:ex_doc, ">= 0.0.0", opts},
2023-08-10 21:01:45 +12:00
{:faker, "~> 0.17", opts},
2023-08-09 20:18:46 +12:00
{:git_ops, "~> 2.6", opts},
{:mix_audit, "~> 2.1", opts},
{:recase, "~> 0.7"},
{:spark, "~> 1.1 and >= 1.1.39"}
2023-08-09 20:18:46 +12:00
]
end
defp aliases do
[
"spark.formatter": "spark.formatter --extensions=Smokestack.Dsl",
"spark.cheat_sheets": "spark.cheat_sheets --extensions=Smokestack.Dsl"
2023-08-09 20:18:46 +12:00
]
end
2023-08-10 21:01:45 +12:00
defp elixirc_paths(env) when env in ~w[dev test]a, do: ~w[lib test/support]
defp elixirc_paths(_), do: ~w[lib]
2023-08-09 20:18:46 +12:00
end