nixpkgs/pkgs/games/lunar-client/default.nix

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

46 lines
1.3 KiB
Nix
Raw Normal View History

{ appimageTools, lib, fetchurl, makeDesktopItem }:
2020-11-13 17:27:46 +00:00
let
name = "lunar-client";
2022-06-10 22:30:54 +00:00
version = "2.10.1";
2020-11-13 17:27:46 +00:00
desktopItem = makeDesktopItem {
name = "lunar-client";
2020-11-13 17:27:46 +00:00
exec = "lunar-client";
icon = "lunarclient";
2022-03-18 19:58:31 +00:00
comment = "Minecraft 1.7, 1.8, 1.12, 1.15, 1.16, 1.17, and 1.18 Client";
2020-11-13 17:27:46 +00:00
desktopName = "Lunar Client";
genericName = "Minecraft Client";
categories = [ "Game" ];
2020-11-13 17:27:46 +00:00
};
appimageContents = appimageTools.extract {
inherit name src;
};
src = fetchurl {
url = "https://launcherupdates.lunarclientcdn.com/Lunar%20Client-${version}.AppImage";
name = "lunar-client.AppImage";
2022-06-10 22:30:54 +00:00
hash = "sha256-3h2FFpIIRta6hEsa/H0xo8+DUvhdQyBv9dqdd/vlwZ4=";
2020-11-13 17:27:46 +00:00
};
2021-12-22 22:30:49 +00:00
in
appimageTools.wrapType1 rec {
2020-11-13 17:27:46 +00:00
inherit name src;
extraInstallCommands = ''
mkdir -p $out/share/applications
cp ${desktopItem}/share/applications/* $out/share/applications
cp -r ${appimageContents}/usr/share/icons/ $out/share/
'';
extraPkgs = pkgs: [ pkgs.libpulseaudio ];
2020-11-13 17:27:46 +00:00
meta = with lib; {
2022-03-18 19:58:31 +00:00
description = "Minecraft 1.7, 1.8, 1.12, 1.15, 1.16, 1.17, and 1.18 Client";
2020-11-13 17:27:46 +00:00
homepage = "https://www.lunarclient.com/";
license = with licenses; [ unfree ];
maintainers = with maintainers; [ zyansheep Technical27 ];
2020-11-13 17:27:46 +00:00
platforms = [ "x86_64-linux" ];
};
}