kaleidotech / elixir-mix-contrib

Ruby like dependency management for Elixir

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Ruby like dependency management for Elixir

Why? Because we love Ruby and the way bundle adds / removes dependencies and we wanted to have the same for our Elixir projects. This package contains 2 mix functionalities, mix deps.add and mix deps.rm. This allows for easy dependency management.

Installation

Add both files to /lib/mix/tasks of your current project and voila. Or, you can run the following command, providing your project directory:

$  mkdir -p PROJECT_DIR/lib/mix/tasks && mv *.ex PROJECT_DIR/lib/mix/tasks

Usage

$ mix deps.add PACKAGE [--version=VERSION --git=GIT_URL]
$ mix deps.rm PACKAGE

Example

$ mix deps.add cowboy
$ mix deps.rm cowboy

FAQ

  1. Is this the best solution? Nope, it was cobbled together quickly, but hey, it works.
  2. Can it be improved? Definitely. Especially error handling.
  3. Can I do it? Of course, feel free to send pull requests.

About

Ruby like dependency management for Elixir

License:MIT License


Languages

Language:Elixir 100.0%