From d09d82eea34bad1faffbd1c979b17a2b073a4d2f Mon Sep 17 00:00:00 2001 From: Jon Banafato Date: Sat, 9 Nov 2019 02:05:02 -0500 Subject: [PATCH] zulip: init at 4.0.0 --- .../instant-messengers/zulip/default.nix | 40 +++++++++++++++++++ pkgs/top-level/all-packages.nix | 2 + 2 files changed, 42 insertions(+) create mode 100644 pkgs/applications/networking/instant-messengers/zulip/default.nix diff --git a/pkgs/applications/networking/instant-messengers/zulip/default.nix b/pkgs/applications/networking/instant-messengers/zulip/default.nix new file mode 100644 index 000000000000..33392af766c9 --- /dev/null +++ b/pkgs/applications/networking/instant-messengers/zulip/default.nix @@ -0,0 +1,40 @@ +{ lib +, fetchurl +, appimageTools +}: + +let + pname = "zulip"; + version = "4.0.0"; + name = "${pname}-${version}"; + + src = fetchurl { + url = "https://github.com/zulip/zulip-desktop/releases/download/v${version}/Zulip-${version}-x86_64.AppImage"; + sha256 = "1pni02mb5bvwx3k45vd6ga269ghdl633gjklyslai24rrhp16h9z"; + name="${pname}-${version}.AppImage"; + }; + + appimageContents = appimageTools.extractType2 { + inherit name src; + }; + +in appimageTools.wrapType2 { + inherit name src; + + extraInstallCommands = '' + mv $out/bin/${name} $out/bin/${pname} + install -m 444 -D ${appimageContents}/zulip.desktop $out/share/applications/zulip.desktop + install -m 444 -D ${appimageContents}/usr/share/icons/hicolor/512x512/apps/zulip.png \ + $out/share/icons/hicolor/512x512/apps/zulip.png + substituteInPlace $out/share/applications/zulip.desktop \ + --replace 'Exec=AppRun' 'Exec=${pname}' + ''; + + meta = with lib; { + description = "Desktop client for Zulip Chat"; + homepage = https://zulipchat.com; + license = licenses.asl20; + maintainers = with maintainers; [ jonafato ]; + platforms = [ "x86_64-linux" ]; + }; +} diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index 180dc5bde59d..7039775b2957 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -8780,6 +8780,8 @@ in z88dk = callPackage ../development/compilers/z88dk { }; + zulip = callPackage ../applications/networking/instant-messengers/zulip { }; + zulu8 = callPackage ../development/compilers/zulu/8.nix { }; zulu = callPackage ../development/compilers/zulu { };