=================
== The Archive ==
=================

[Elixir] Elixir 프로젝트에 의존성 설치하기

|

AI Summary

  • Elixir 프로젝트에 의존성을 추가하려면 mix.exs 파일의 defp deps do 함수 내에 라이브러리를 명시한다.
  • 예시로 {:guardian, "~> 2.0"} 같은 형식으로 새 라이브러리를 추가할 수 있다.
  • 추가 후 mix deps.get 명령어로 라이브러리를 가져오고 mix deps.compile로 컴파일한다.
  • 특정 라이브러리 정보를 확인하려면 mix hex.info 라이브러리명 명령어를 사용한다.
  • 이 명령어는 라이선스, 버전, 릴리즈 정보 등을 보여준다.
  • 공식 문서와 참고 링크를 통해 더 자세한 의존성 관리 방법을 확인할 수 있다.
Updated: 2025-11-22 15:35 UTC

개요

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
  defp deps do
    [
      {:phoenix, "~> 1.7.10"},
      {:phoenix_ecto, "~> 4.4"},
      {:ecto_sql, "~> 3.10"},
      {:postgrex, ">= 0.0.0"},
      {:phoenix_live_dashboard, "~> 0.8.2"},
      {:swoosh, "~> 1.3"},
      {:finch, "~> 0.13"},
      {:telemetry_metrics, "~> 0.6"},
      {:telemetry_poller, "~> 1.0"},
      {:gettext, "~> 0.20"},
      {:jason, "~> 1.2"},
      {:dns_cluster, "~> 0.1.1"},
      {:plug_cowboy, "~> 2.5"},
      {:bcrypt_elixir, "~> 3.0"}, # 새로 추가한 라이브러리
      {:guardian, "~> 2.0"} # 새로 추가한 라이브러리
    ]
  end
1
2
$ mix deps.get
$ mix deps.compile

정보 확인하는 방법

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
❯ mix hex.info bcrypt_elixir
Bcrypt password hashing algorithm for Elixir

Config: {:bcrypt_elixir, "~> 3.1"}
Locked version: 3.1.0
Releases: 3.1.0, 3.0.1, 3.0.0, 2.3.1, 2.3.0, 2.2.0, 2.1.0, 2.0.3, ...

Licenses: BSD-3-Clause, ISC, BSD-4-Clause
Links:
  Changelog: https://github.com/riverrun/bcrypt_elixir/blob/master/CHANGELOG.md
  GitHub: https://github.com/riverrun/bcrypt_elixir

References

Categories:

Tags: