DEP
- basic dependency tracking
dep check
dep add libname [--pre]
dep rm libname
dep install
Checks that all dependencies are met.
Fetches the latest version of the library in question and automatically adds it to your .gems file.
Simply removes the corresponding entry in your .gems file.
Installs all the missing dependencies for you. An important
point here is that it simply does a gem install
for each
dependency you have. Dep assumes that you use some form of
sandboxing like gs, RVM or rbenv-gemset.
$ gem install dep
dep is actually more of a workflow than a tool. If you think about package managers and the problem of dependencies, you can summarize what you absolutely need from them in just two points:
The first approach is handled by vendoring the library. The second approach typically is done using Bundler. But why do you need such a complicated tool when all you need is simply listing version numbers?
We dissected what we were doing and eventually reached the following workflow:
So after doing this workflow manually for a while, we decided to build the simplest tool to aid us with our workflow.
The manual workflow for dep add
would be:
gem search -r "^ohm$" [--pre] # check and remember the version number
echo "ohm -v X.x.x" >> .gems
If you try doing that repeatedly, it will quickly become cumbersome.
The fourth and final point is handled by typing dep check or simply dep. Practically speaking it's just:
git pull
dep
And that's it. The dep command typically happens in 0.2 seconds which is something we LOVE.