ruby: add a new .dev output to ruby derivations
The idea is to bundle ruby, bundler and bundix together. I was having issues where bundler was installed with ruby 2.3.0 and I wanted to use ruby 2.0.0. With this change all the developer has to do is install `ruby_2_0_0.dev` either in his environment or in a nix-shell.
This commit is contained in:
@@ -0,0 +1,24 @@
|
||||
/* An environment for development that bundles ruby, bundler and bundix
|
||||
together. This avoids version conflicts where each is using a diferent
|
||||
version of each-other.
|
||||
*/
|
||||
{ buildEnv, ruby, bundler, bundix }:
|
||||
let
|
||||
bundler_ = bundler.override {
|
||||
ruby = ruby;
|
||||
};
|
||||
bundix_ = bundix.override {
|
||||
ruby = ruby;
|
||||
bundler = bundler_;
|
||||
};
|
||||
in
|
||||
buildEnv {
|
||||
name = "${ruby.rubyEngine}-dev-${ruby.version}";
|
||||
paths = [
|
||||
bundix_
|
||||
bundler_
|
||||
ruby
|
||||
];
|
||||
pathsToLink = [ "/bin" ];
|
||||
ignoreCollisions = true;
|
||||
}
|
||||
Reference in New Issue
Block a user