2024-06-21 01:06:20 +01:00
|
|
|
{
|
|
|
|
fetchurl,
|
|
|
|
appimageTools,
|
|
|
|
|
|
|
|
pname,
|
|
|
|
version,
|
|
|
|
meta,
|
2024-07-07 21:54:26 +01:00
|
|
|
passthru,
|
2024-06-21 01:06:20 +01:00
|
|
|
}:
|
|
|
|
|
|
|
|
appimageTools.wrapType2 rec {
|
2024-07-07 21:54:26 +01:00
|
|
|
inherit
|
|
|
|
pname
|
|
|
|
version
|
|
|
|
meta
|
|
|
|
passthru
|
|
|
|
;
|
2024-06-21 01:06:20 +01:00
|
|
|
|
|
|
|
src = fetchurl {
|
|
|
|
url = "https://github.com/ThaUnknown/miru/releases/download/v${version}/linux-Miru-${version}.AppImage";
|
|
|
|
name = "${pname}-${version}.AppImage";
|
2024-11-12 09:10:51 +00:00
|
|
|
hash = "sha256-4ueVgIcIi/RIFRoDKStiNqszfaIXZ9dfagddzCVaSRs=";
|
2024-06-21 01:06:20 +01:00
|
|
|
};
|
|
|
|
|
|
|
|
extraInstallCommands =
|
|
|
|
let
|
|
|
|
contents = appimageTools.extractType2 { inherit pname version src; };
|
|
|
|
in
|
|
|
|
''
|
|
|
|
mkdir -p "$out/share/applications"
|
|
|
|
mkdir -p "$out/share/lib/miru"
|
|
|
|
cp -r ${contents}/{locales,resources} "$out/share/lib/miru"
|
|
|
|
cp -r ${contents}/usr/* "$out"
|
|
|
|
cp "${contents}/${pname}.desktop" "$out/share/applications/"
|
|
|
|
substituteInPlace $out/share/applications/${pname}.desktop --replace 'Exec=AppRun' 'Exec=${pname}'
|
|
|
|
'';
|
|
|
|
}
|