summaryrefslogtreecommitdiff
path: root/mix.exs
blob: f3aa38d77f62ada47ba2292cc84b5905812d7c7c (plain) (blame)
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
defmodule PolyjuiceClient.MixProject do
  use Mix.Project

  def project do
    [
      app: :polyjuice_client,
      description: "Client library for the Matrix.org communications protocol",
      version: "0.3.1",
      elixir: "~> 1.7",
      start_permanent: Mix.env() == :prod,
      deps: deps(),
      elixirc_paths: elixirc_paths(Mix.env()),

      # Docs
      name: "Polyjuice Client",
      source_url: "https://gitlab.com/uhoreg/polyjuice_client",
      # homepage_url: "https://www.uhoreg.ca/programming/matrix/polyjuice",
      docs: [
        # The main page in the docs
        main: "readme",
        # logo: "path/to/logo.png",
        extras: [
          "README.md",
          "tutorial_echo.md",
          "tutorial_welcome.md"
        ],
        groups_for_modules: [
          Endpoints: [
            ~r/Polyjuice\.Client\.Endpoint\.Get.*/,
            ~r/Polyjuice\.Client\.Endpoint\.Post.*/,
            ~r/Polyjuice\.Client\.Endpoint\.Put.*/
          ]
        ]
      ],
      package: [
        maintainers: ["Hubert Chathi"],
        licenses: ["Apache-2.0"],
        links: %{
          "Source" => "https://gitlab.com/uhoreg/polyjuice_client"
        }
      ],

      # Tests
      test_coverage: [
        summary: [threshold: false]
      ]
    ]
  end

  def application do
    [
      mod: {Polyjuice.Client.Application, []},
      extra_applications: [:logger]
    ]
  end

  defp deps do
    [
      {:ex_doc, "~> 0.21", only: :dev, runtime: false},
      {:hackney, "~> 1.12"},
      {:jason, "~> 1.2"},
      {:polyjuice_util, "~> 0.1.0"},
      {:mutex, "~> 1.1.3"}
    ]
  end

  defp elixirc_paths(:test), do: ["lib", "test/support"]
  defp elixirc_paths(_), do: ["lib"]
end