2024-06-24 18:47:55 +00:00
|
|
|
{
|
|
|
|
fetchurl,
|
|
|
|
appimageTools,
|
|
|
|
|
|
|
|
pname,
|
|
|
|
version,
|
|
|
|
meta,
|
|
|
|
}:
|
|
|
|
|
|
|
|
appimageTools.wrapType2 rec {
|
|
|
|
inherit pname version meta;
|
|
|
|
|
|
|
|
src = fetchurl {
|
|
|
|
url = "https://github.com/ThaUnknown/miru/releases/download/v${version}/linux-Miru-${version}.AppImage";
|
|
|
|
name = "${pname}-${version}.AppImage";
|
2024-07-01 15:47:52 +00:00
|
|
|
sha256 = "sha256-wnqCKnZKt0Fj8TasdRVzI558W7aIB5FLkcDEiZfz3ZQ=";
|
2024-06-24 18:47:55 +00: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}'
|
|
|
|
'';
|
|
|
|
}
|