2018-07-16 03:12:17 +01:00
|
|
|
{ stdenv, fetchurl, makeWrapper, jre, makeDesktopItem, lib }:
|
|
|
|
|
2019-11-25 11:23:51 +00:00
|
|
|
stdenv.mkDerivation rec {
|
2019-08-15 13:41:18 +01:00
|
|
|
pname = "runelite";
|
2019-11-25 11:23:51 +00:00
|
|
|
version = "2.0.0";
|
2018-07-16 03:12:17 +01:00
|
|
|
|
|
|
|
src = fetchurl {
|
|
|
|
url = "https://github.com/runelite/launcher/releases/download/${version}/RuneLite.jar";
|
2019-11-25 11:23:51 +00:00
|
|
|
sha256 = "0q0x8g43ggkvp5fgnymgygx59xfhnyyrhpi6ha333gqg97rr0rvw";
|
2018-07-16 03:12:17 +01:00
|
|
|
};
|
|
|
|
|
|
|
|
icon = fetchurl {
|
2019-11-25 11:23:51 +00:00
|
|
|
url = "https://github.com/runelite/launcher/raw/${version}/appimage/runelite.png";
|
|
|
|
sha256 = "04fcjm7p546gr82g0jbh497j7rnh70lrvas0k171bff4v3knrjw1";
|
2018-07-16 03:12:17 +01:00
|
|
|
};
|
|
|
|
|
|
|
|
desktop = makeDesktopItem {
|
|
|
|
name = "RuneLite";
|
|
|
|
type = "Application";
|
|
|
|
exec = "runelite";
|
2019-09-09 00:38:31 +01:00
|
|
|
icon = icon;
|
2018-07-16 03:12:17 +01:00
|
|
|
comment = "Open source Old School RuneScape client";
|
|
|
|
terminal = "false";
|
|
|
|
desktopName = "RuneLite";
|
|
|
|
genericName = "Oldschool Runescape";
|
2020-06-25 03:18:37 +01:00
|
|
|
categories = "Game";
|
2018-07-16 03:12:17 +01:00
|
|
|
startupNotify = null;
|
|
|
|
};
|
|
|
|
|
|
|
|
buildInputs = [ makeWrapper ];
|
|
|
|
|
|
|
|
# colon is bash form of no-op (do nothing)
|
2019-06-19 16:45:34 +01:00
|
|
|
dontUnpack = true;
|
2018-07-16 03:12:17 +01:00
|
|
|
|
|
|
|
installPhase = ''
|
|
|
|
mkdir -p $out/share/runelite
|
|
|
|
mkdir -p $out/share/applications
|
|
|
|
|
|
|
|
ln -s ${src} $out/share/runelite/RuneLite.jar
|
|
|
|
ln -s ${desktop}/share/applications/* $out/share/applications
|
|
|
|
|
|
|
|
makeWrapper ${jre}/bin/java $out/bin/runelite \
|
|
|
|
--add-flags "-jar $out/share/runelite/RuneLite.jar"
|
|
|
|
'';
|
|
|
|
|
2019-11-25 11:23:51 +00:00
|
|
|
meta = with lib; {
|
2018-07-16 03:12:17 +01:00
|
|
|
description = "Open source Old School RuneScape client";
|
|
|
|
homepage = "https://runelite.net/";
|
2019-11-25 11:23:51 +00:00
|
|
|
license = licenses.bsd2;
|
|
|
|
maintainers = with maintainers; [ kmeakin ];
|
|
|
|
platforms = platforms.all;
|
2018-07-16 03:12:17 +01:00
|
|
|
};
|
2019-11-25 11:23:51 +00:00
|
|
|
}
|