defmodule RefInspector.Plug.MixProject do use Mix.Project @url_changelog "https://hexdocs.pm/ref_inspector_plug/changelog.html" @url_github "https://github.com/elixir-inspector/ref_inspector_plug" @version "0.2.0" def project do [ app: :ref_inspector_plug, name: "RefInspector Plug", version: @version, elixir: "~> 1.9", deps: deps(), description: "RefInspector Plug", dialyzer: dialyzer(), docs: docs(), elixirc_paths: elixirc_paths(Mix.env()), package: package(), preferred_cli_env: [ coveralls: :test, "coveralls.detail": :test ], test_coverage: [tool: ExCoveralls] ] end defp deps do [ {:credo, "~> 1.6", only: :dev, runtime: false}, {:dialyxir, "~> 1.2", only: :dev, runtime: false}, {:ex_doc, ">= 0.0.0", only: :dev, runtime: false}, {:excoveralls, "~> 0.14.0", only: :test, runtime: false}, {:plug, "~> 1.0"}, {:ref_inspector, "~> 2.0"} ] end defp dialyzer do [ flags: [ :error_handling, :underspecs, :unmatched_returns ], plt_core_path: "plts", plt_local_path: "plts" ] end defp docs do [ extras: [ "CHANGELOG.md", LICENSE: [title: "License"], "README.md": [title: "Overview"] ], formatters: ["html"], main: "RefInspector.Plug", source_ref: "v#{@version}", source_url: @url_github ] end defp elixirc_paths(:test), do: ["lib", "test/helpers"] defp elixirc_paths(_), do: ["lib"] defp package do %{ files: ["CHANGELOG.md", "LICENSE", "mix.exs", "README.md", "lib"], licenses: ["Apache-2.0"], links: %{ "Changelog" => @url_changelog, "GitHub" => @url_github } } end end