remarkjs: use node2nix generated expressions

(cherry picked from commit 0f591992df1e7abe8e324e53a8970e20afac267d)
This commit is contained in:
Sander van der Burg 2016-09-02 13:00:16 +00:00
parent 4cac903456
commit fcbaf2bc23
5 changed files with 2994 additions and 6 deletions

View File

@ -1,4 +1,4 @@
{ stdenv, lib, fetchgit, fetchurl, nodejs, nodePackages }: { stdenv, lib, fetchgit, fetchurl, nodejs, phantomjs2, pkgs }:
with lib; with lib;
@ -11,6 +11,11 @@ let
sha256 = "1yy8by15kfklw8lwh17z1swpj067q0skjjih12yawbryraig41m0"; sha256 = "1yy8by15kfklw8lwh17z1swpj067q0skjjih12yawbryraig41m0";
}; };
nodePackages = import ./nodepkgs.nix {
inherit pkgs;
inherit (stdenv) system;
};
in stdenv.mkDerivation rec { in stdenv.mkDerivation rec {
name = "remarkjs-${version}"; name = "remarkjs-${version}";
@ -21,20 +26,18 @@ in stdenv.mkDerivation rec {
sha256 = "1a2il6aa0g9cnig56ykmq8lr626pbxlsllk6js41h6gcn214rw60"; sha256 = "1a2il6aa0g9cnig56ykmq8lr626pbxlsllk6js41h6gcn214rw60";
}; };
buildInputs = with nodePackages; [ buildInputs = [ nodejs phantomjs2 ] ++ (with nodePackages; [
nodejs
marked marked
browserify browserify
uglify-js uglify-js
less less
mocha mocha
mocha-phantomjs #mocha-phantomjs
phantomjs
should should
sinon sinon
jshint jshint
shelljs shelljs
]; ]);
configurePhase = '' configurePhase = ''
mkdir -p node_modules/.bin mkdir -p node_modules/.bin

View File

@ -0,0 +1,3 @@
#!/bin/sh -e
node2nix -i pkgs.json -c nodepkgs.nix -e ../../node-packages/node-env.nix

File diff suppressed because it is too large Load Diff

View File

@ -0,0 +1,16 @@
# This file has been generated by node2nix 1.0.1. Do not edit!
{pkgs ? import <nixpkgs> {
inherit system;
}, system ? builtins.currentSystem, nodejs ? pkgs."nodejs"}:
let
nodeEnv = import ../../node-packages/node-env.nix {
inherit (pkgs) stdenv python utillinux runCommand writeTextFile;
inherit nodejs;
};
in
import ./node-packages.nix {
inherit (pkgs) fetchurl fetchgit;
inherit nodeEnv;
}

View File

@ -0,0 +1,12 @@
[
"marked"
, "browserify"
, "uglify-js"
, "less"
, "mocha"
, "mocha-phantomjs"
, "should"
, "sinon"
, "jshint"
, "shelljs"
]