aboutsummaryrefslogtreecommitdiff
path: root/pkgs
diff options
context:
space:
mode:
authorKarel Kočí <cynerd@email.cz>2022-06-20 09:07:23 +0200
committerKarel Kočí <cynerd@email.cz>2022-06-20 09:08:09 +0200
commit1165f7fb0e1e926d64dd9dd14d121004061460a6 (patch)
treec7c76c4c9ba19e185f0a3bd9d8bc260541141375 /pkgs
parent59d8351f0f60fafea11310fdff417b3a10849b0f (diff)
downloadnixos-personal-1165f7fb0e1e926d64dd9dd14d121004061460a6.tar.gz
nixos-personal-1165f7fb0e1e926d64dd9dd14d121004061460a6.tar.bz2
nixos-personal-1165f7fb0e1e926d64dd9dd14d121004061460a6.zip
pkgs: add update version of heroic
Diffstat (limited to 'pkgs')
-rw-r--r--pkgs/default.nix1
-rw-r--r--pkgs/heroic/default.nix37
2 files changed, 38 insertions, 0 deletions
diff --git a/pkgs/default.nix b/pkgs/default.nix
index c015f7c..ff1ceea 100644
--- a/pkgs/default.nix
+++ b/pkgs/default.nix
@@ -27,6 +27,7 @@ let
nixpkgs.path + "/pkgs/applications/networking/instant-messengers/franz/generic.nix"
) { };
};
+ heroic = callPackage ./heroic { };
};
diff --git a/pkgs/heroic/default.nix b/pkgs/heroic/default.nix
new file mode 100644
index 0000000..5eba770
--- /dev/null
+++ b/pkgs/heroic/default.nix
@@ -0,0 +1,37 @@
+{ lib, fetchurl, appimageTools }:
+
+let
+ pname = "heroic";
+ version = "2.3.9";
+ name = "${pname}-${version}";
+ src = fetchurl {
+ url = "https://github.com/Heroic-Games-Launcher/HeroicGamesLauncher/releases/download/v${version}/Heroic-${version}.AppImage";
+ sha256 = "17jzrh4qqcxvib9bbk2x224xwg67n6z5xsc9978w9vxb04mr0x7d";
+ };
+ appimageContents = appimageTools.extractType2 { inherit name src; };
+
+in appimageTools.wrapType2 {
+ inherit name version src;
+
+ extraInstallCommands = ''
+ mv $out/bin/${name} $out/bin/${pname}
+
+ mkdir -p $out/share/${pname}
+ cp -a ${appimageContents}/locales $out/share/${pname}
+ cp -a ${appimageContents}/resources $out/share/${pname}
+
+ install -m 444 -D ${appimageContents}/heroic.desktop -t $out/share/applications
+
+ cp -a ${appimageContents}/usr/share/icons $out/share/
+
+ substituteInPlace $out/share/applications/heroic.desktop \
+ --replace 'Exec=AppRun' 'Exec=heroic'
+ '';
+
+ meta = with lib; {
+ description = "A Native GUI Epic Games Launcher for Linux, Windows and Mac";
+ homepage = "https://github.com/Heroic-Games-Launcher/HeroicGamesLauncher";
+ license = licenses.gpl3Only;
+ platforms = [ "x86_64-linux" ];
+ };
+}