2016-04-30 11:11:00 +02:00
|
|
|
{ stdenv, fetchFromGitHub, phantomjs, python, nodePackages }:
|
2012-12-13 17:39:16 +01:00
|
|
|
|
2016-04-30 11:11:00 +02:00
|
|
|
let version = "1.0.0-RC5";
|
2012-12-13 17:39:16 +01:00
|
|
|
|
2016-04-30 11:11:00 +02:00
|
|
|
in stdenv.mkDerivation rec {
|
|
|
|
|
|
|
|
name = "casperjs-${version}";
|
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "casperjs";
|
|
|
|
repo = "casperjs";
|
|
|
|
rev = version;
|
|
|
|
sha256 = "10b25jmh9zmlp77h0p3n9d6bnl3wn4iv3h3qnsrgijfszxyh0wgw";
|
2012-12-13 17:39:16 +01:00
|
|
|
};
|
|
|
|
|
2016-04-30 11:11:00 +02:00
|
|
|
buildInputs = [ phantomjs python nodePackages.eslint ];
|
|
|
|
|
2012-12-13 17:39:16 +01:00
|
|
|
patchPhase = ''
|
|
|
|
substituteInPlace bin/casperjs --replace "/usr/bin/env python" "${python}/bin/python" \
|
|
|
|
--replace "'phantomjs'" "'${phantomjs}/bin/phantomjs'"
|
|
|
|
'';
|
|
|
|
|
2016-04-30 11:11:00 +02:00
|
|
|
dontBuild = true;
|
|
|
|
|
2012-12-13 17:39:16 +01:00
|
|
|
installPhase = ''
|
2016-04-30 11:11:00 +02:00
|
|
|
mv $PWD $out
|
2012-12-13 17:39:16 +01:00
|
|
|
'';
|
|
|
|
|
|
|
|
meta = {
|
2016-04-30 11:11:00 +02:00
|
|
|
|
|
|
|
description = ''
|
|
|
|
Navigation scripting & testing utility for PhantomJS and SlimerJS
|
|
|
|
'';
|
|
|
|
|
2012-12-13 17:39:16 +01:00
|
|
|
longDescription = ''
|
2016-04-30 11:11:00 +02:00
|
|
|
CasperJS is a navigation scripting & testing utility for PhantomJS and
|
|
|
|
SlimerJS (still experimental). It eases the process of defining a full
|
|
|
|
navigation scenario and provides useful high-level functions, methods &
|
|
|
|
syntactic sugar for doing common tasks.
|
2012-12-13 17:39:16 +01:00
|
|
|
'';
|
|
|
|
|
|
|
|
homepage = http://casperjs.org;
|
|
|
|
license = stdenv.lib.licenses.mit;
|
|
|
|
|
|
|
|
maintainers = [ stdenv.lib.maintainers.bluescreen303 ];
|
2013-10-08 11:05:19 +02:00
|
|
|
platforms = stdenv.lib.platforms.linux;
|
2012-12-13 17:39:16 +01:00
|
|
|
};
|
|
|
|
}
|