Packages

Reader for the glTF 2.0 3D interchange format — .gltf and .glb, with accessor decoding that handles interleaved strides and sparse substitution.

Current section

Files

Jump to
gltf mix.exs
Raw

mix.exs

defmodule Gltf.MixProject do
use Mix.Project
@version "0.1.0"
@source_url "https://github.com/mdon/gltf"
def project do
[
app: :gltf,
version: @version,
elixir: "~> 1.18",
elixirc_paths: elixirc_paths(Mix.env()),
start_permanent: Mix.env() == :prod,
deps: deps(),
aliases: aliases(),
# Hex
description:
"Reader for the glTF 2.0 3D interchange format — .gltf and .glb, with accessor decoding that handles interleaved strides and sparse substitution.",
package: package(),
# Dialyzer
dialyzer: [ignore_warnings: ".dialyzer_ignore.exs"],
# Test coverage — production code only.
test_coverage: [ignore_modules: [~r/^Gltf\.Test\./]],
# Docs
name: "Gltf",
source_url: @source_url,
docs: docs()
]
end
def application do
[extra_applications: [:logger]]
end
defp elixirc_paths(:test), do: ["lib", "test/support"]
defp elixirc_paths(_), do: ["lib"]
defp aliases do
[
quality: ["format", "credo --strict", "dialyzer"],
"quality.ci": ["format --check-formatted", "credo --strict", "dialyzer"],
precommit: [
"compile --force --warnings-as-errors",
"deps.unlock --check-unused",
# Run via `cmd` so Hex bootstraps in a fresh process — the hex.* archive
# tasks aren't resolvable via Mix.Task.run inside an alias.
"cmd mix hex.audit",
"quality.ci",
# Also via `cmd`: `mix test` inside an alias would inherit the dev
# environment and refuse to run.
"cmd mix test"
]
]
end
defp deps do
[
{:jason, "~> 1.4"},
{:ex_doc, "~> 0.34", only: :dev, runtime: false},
{:credo, "~> 1.7", only: [:dev, :test], runtime: false},
{:dialyxir, "~> 1.4", only: [:dev, :test], runtime: false}
]
end
defp package do
[
licenses: ["MIT"],
links: %{"GitHub" => @source_url},
files: ~w(lib .formatter.exs mix.exs README.md CHANGELOG.md LICENSE)
]
end
defp docs do
[
main: "Gltf",
source_ref: "v#{@version}",
extras: ["README.md", "CHANGELOG.md"]
]
end
end