1 { stdenv, lib, fetchzip, autoPatchelfHook, xorg, gtk2, gnome2, gtk3, nss, alsaLib, udev, unzip, wrapGAppsHook }:
3 stdenv.mkDerivation rec {
8 url = "https://cdn.cypress.io/desktop/${version}/linux-x64/cypress.zip";
9 sha256 = "1m52v6hhblrjji9c5885bn5qq0xlaw36krbmqfac7fhgsxmkxd2h";
12 # don't remove runtime deps
15 nativeBuildInputs = [ autoPatchelfHook wrapGAppsHook unzip ];
17 buildInputs = with xorg; [
18 libXScrnSaver libXdamage libXtst libxshmfence
20 nss gtk2 alsaLib gnome2.GConf gtk3
23 runtimeDependencies = [ (lib.getLib udev) ];
28 mkdir -p $out/bin $out/opt/cypress
29 cp -vr * $out/opt/cypress/
30 # Let's create the file binary_state ourselves to make the npm package happy on initial verification.
31 # Cypress now verifies version by reading bin/resources/app/package.json
32 mkdir -p $out/bin/resources/app
33 printf '{"version":"%b"}' $version > $out/bin/resources/app/package.json
34 # Cypress now looks for binary_state.json in bin
35 echo '{"verified": true}' > $out/binary_state.json
36 ln -s $out/opt/cypress/Cypress $out/bin/Cypress
42 description = "Fast, easy and reliable testing for anything that runs in a browser";
43 homepage = "https://www.cypress.io";
44 license = licenses.mit;
45 platforms = ["x86_64-linux"];
46 maintainers = with maintainers; [ tweber mmahut ];