Skip to content

Commit

Permalink
Include environment for mix dependencies
Browse files Browse the repository at this point in the history
  • Loading branch information
trenpixster committed Jan 20, 2015
1 parent a416c41 commit e7e492a
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 3 deletions.
13 changes: 10 additions & 3 deletions mix.exs
Original file line number Diff line number Diff line change
Expand Up @@ -7,23 +7,30 @@ defmodule Addict.Mixfile do
elixir: "~> 1.0",
description: description,
package: package,
deps: deps]
deps: deps(Mix.env)]
end

def application do
[applications: [:logger, :bcrypt]]
end

defp deps(:test) do
[{:cowboy, "~> 1.0"}, {:mock, "~> 0.1.0"}] ++ deps(:prod)
end

defp deps do
defp deps(:prod) do
[{:phoenix, "~> 0.8.0"},
{:ecto, "~> 0.6.0"},
{:bcrypt, github: "opscode/erlang-bcrypt"},
{:mailgun, "~> 0.0.2"}]
end

defp deps(_) do
deps(:prod)
end

defp package do
[# These are the default files included in the package
[
files: ["lib", "mix.exs", "README*", "LICENSE*"],
contributors: ["Nizar Venturini"],
licenses: ["MIT"],
Expand Down
2 changes: 2 additions & 0 deletions mix.lock
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,8 @@
"decimal": {:hex, :decimal, "0.2.5"},
"ecto": {:hex, :ecto, "0.6.0"},
"mailgun": {:hex, :mailgun, "0.0.2"},
"meck": {:hex, :meck, "0.8.2"},
"mock": {:hex, :mock, "0.1.0"},
"phoenix": {:hex, :phoenix, "0.8.0"},
"plug": {:hex, :plug, "0.9.0"},
"poison": {:hex, :poison, "1.3.0"},
Expand Down

0 comments on commit e7e492a

Please sign in to comment.