nixpkgs/pkgs/development/tools/yarn/default.nix
Gauthier POGAM--LE MONTAGNER 870914fc41 yarn: 0.19.1 -> 0.20.3
2017-02-25 14:42:21 +01:00

27 lines
737 B
Nix

{ stdenv, nodejs, fetchzip, makeWrapper }:
stdenv.mkDerivation rec {
name = "yarn-${version}";
version = "0.20.3";
src = fetchzip {
url = "https://github.com/yarnpkg/yarn/releases/download/v${version}/yarn-v${version}.tar.gz";
sha256 = "1w4n05155rlkyv9k43fs0zrl04pri89vbi7rzpwmcg6zfxz273lw";
};
buildInputs = [makeWrapper nodejs];
installPhase = ''
mkdir -p $out/{bin,libexec/yarn/}
cp -R . $out/libexec/yarn
makeWrapper $out/libexec/yarn/bin/yarn.js $out/bin/yarn
'';
meta = with stdenv.lib; {
homepage = https://yarnpkg.com/;
description = "Fast, reliable, and secure dependency management for javascript";
license = licenses.bsd2;
maintainers = [ maintainers.offline ];
};
}