nixpkgs/pkgs/development/tools/vagrant/default.nix

56 lines
1.2 KiB
Nix
Raw Normal View History

{ lib, fetchurl, buildRubyGem, bundlerEnv, ruby }:
2013-11-21 23:21:39 +01:00
2014-11-18 05:24:07 +01:00
let
version = "2.0.1";
url = "https://github.com/hashicorp/vagrant/archive/v${version}.tar.gz";
sha256 = "1fjfl00n4rsq6khypm56g0vq6l153q128r35zky2ba30bz292ar1";
deps = bundlerEnv rec {
name = "${pname}-${version}";
pname = "vagrant";
inherit version;
inherit ruby;
gemdir = ./.;
gemset = lib.recursiveUpdate (import ./gemset.nix) {
vagrant = {
source = {
type = "url";
inherit url sha256;
};
inherit version;
};
};
};
2014-11-18 05:24:07 +01:00
in buildRubyGem rec {
name = "${gemName}-${version}";
gemName = "vagrant";
inherit version;
doCheck = true;
dontBuild = false;
src = fetchurl { inherit url sha256; };
patches = [
./unofficial-installation-nowarn.patch
];
postInstall = ''
wrapProgram "$out/bin/vagrant" \
--set GEM_PATH "${deps}/lib/ruby/gems/${ruby.version.libDir}"
'';
2013-11-21 23:21:39 +01:00
passthru = {
inherit ruby deps;
};
meta = with lib; {
2013-11-21 23:21:39 +01:00
description = "A tool for building complete development environments";
homepage = https://www.vagrantup.com/;
license = licenses.mit;
maintainers = with maintainers; [ aneeshusa ];
platforms = with platforms; linux ++ darwin;
2013-11-21 23:21:39 +01:00
};
}