From 0aa29fa4d8a8bf0e96e83993a624f61fab73c59f Mon Sep 17 00:00:00 2001 From: NWDD Date: Sun, 5 Mar 2017 16:38:55 +0100 Subject: [PATCH] gitkraken: init at 2.1.0 --- .../version-management/gitkraken/default.nix | 74 +++++++++++++++++++ pkgs/top-level/all-packages.nix | 2 + 2 files changed, 76 insertions(+) create mode 100644 pkgs/applications/version-management/gitkraken/default.nix diff --git a/pkgs/applications/version-management/gitkraken/default.nix b/pkgs/applications/version-management/gitkraken/default.nix new file mode 100644 index 000000000000..70ca7a74b236 --- /dev/null +++ b/pkgs/applications/version-management/gitkraken/default.nix @@ -0,0 +1,74 @@ +{stdenv, lib, libXcomposite, libgnome_keyring, makeWrapper, udev, curl, alsaLib + ,libXfixes, atk, gtk2, libXrender, pango, gnome2, cairo, freetype, fontconfig + ,libX11, libXi, libXext, libXcursor, glib, libXScrnSaver, libxkbfile, libXtst + ,nss, nspr, cups, fetchurl, expat, gdk_pixbuf, libXdamage, libXrandr, dbus +}: + +stdenv.mkDerivation rec { + name = "gitkraken-${version}"; + version = "2.1.0"; + + src = fetchurl { + url = "https://release.gitkraken.com/linux/v${version}.tar.gz"; + sha256 = "56b5657f5c13fa1d8f6b7b9331194cbc8c48c0b913e5f0fb561d0e9af82f7999"; + }; + + libPath = stdenv.lib.makeLibraryPath [ + stdenv.cc.cc.lib + curl + udev + libX11 + libXext + libXcursor + libXi + glib + libXScrnSaver + libxkbfile + libXtst + nss + nspr + cups + alsaLib + expat + gdk_pixbuf + dbus + libXdamage + libXrandr + atk + pango + cairo + freetype + fontconfig + libXcomposite + libXfixes + libXrender + gtk2 + gnome2.GConf + libgnome_keyring + ]; + + phases = [ "unpackPhase" "installPhase" ]; + + buildInputs = [ makeWrapper ]; + + installPhase = '' + mkdir -p "$out/opt/gitkraken" + cp -r ./* "$out/opt/gitkraken" + fixupPhase + patchelf --set-interpreter $(cat $NIX_CC/nix-support/dynamic-linker) \ + --set-rpath "$libPath:$out/opt/gitkraken" "$out/opt/gitkraken/gitkraken" + wrapProgram $out/opt/gitkraken/gitkraken \ + --prefix LD_PRELOAD : "${stdenv.lib.makeLibraryPath [ curl ]}/libcurl.so.4" \ + --prefix LD_PRELOAD : "${stdenv.lib.makeLibraryPath [ libgnome_keyring ]}/libgnome-keyring.so.0" + mkdir "$out/bin" + ln -s "$out/opt/gitkraken/gitkraken" "$out/bin/gitkraken" + ''; + + meta = with stdenv.lib; { + homepage = https://www.gitkraken.com/; + description = "The downright luxurious and most popular Git client for Windows, Mac & Linux"; + license = licenses.unfree; + platforms = platforms.linux; + maintainers = [ ]; + }; +} diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index 43743b5c83bc..5457886d5307 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -1918,6 +1918,8 @@ with pkgs; gitinspector = callPackage ../applications/version-management/gitinspector { }; + gitkraken = callPackage ../applications/version-management/gitkraken { }; + gitlab = callPackage ../applications/version-management/gitlab { }; gitlab-runner = callPackage ../development/tools/continuous-integration/gitlab-runner { };