2022-12-02 08:20:57 +00:00
|
|
|
{ lib
|
|
|
|
, appimageTools
|
|
|
|
, fetchurl
|
|
|
|
}:
|
|
|
|
let
|
|
|
|
pname = "motrix";
|
2023-05-24 13:37:59 +00:00
|
|
|
version = "1.8.19";
|
2022-12-02 08:20:57 +00:00
|
|
|
|
|
|
|
src = fetchurl {
|
|
|
|
url = "https://github.com/agalwood/Motrix/releases/download/v${version}/Motrix-${version}.AppImage";
|
2023-05-24 13:37:59 +00:00
|
|
|
hash = "sha256-oSO+VH3bZcjnXjECqZgOmsvlOONbfgOq50qVLvHdKfo=";
|
2022-12-02 08:20:57 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
appimageContents = appimageTools.extractType2 {
|
|
|
|
inherit pname version src;
|
|
|
|
};
|
|
|
|
in
|
2023-05-24 13:37:59 +00:00
|
|
|
appimageTools.wrapType2 {
|
2022-12-02 08:20:57 +00:00
|
|
|
inherit pname version src;
|
|
|
|
|
|
|
|
extraInstallCommands = ''
|
2023-05-24 13:37:59 +00:00
|
|
|
install -Dm 444 ${appimageContents}/${pname}.desktop -t $out/share/applications
|
2022-12-02 08:20:57 +00:00
|
|
|
cp -r ${appimageContents}/usr/share/icons $out/share
|
2023-05-24 13:37:59 +00:00
|
|
|
|
|
|
|
substituteInPlace $out/share/applications/${pname}.desktop \
|
|
|
|
--replace 'Exec=AppRun' 'Exec=${pname}'
|
2022-12-02 08:20:57 +00:00
|
|
|
'';
|
|
|
|
|
|
|
|
meta = with lib; {
|
2024-06-20 14:57:18 +00:00
|
|
|
description = "Full-featured download manager";
|
2022-12-02 08:20:57 +00:00
|
|
|
homepage = "https://motrix.app";
|
|
|
|
license = licenses.mit;
|
|
|
|
platforms = [ "x86_64-linux" ];
|
2023-05-24 13:37:59 +00:00
|
|
|
sourceProvenance = with sourceTypes; [ binaryNativeCode ];
|
2022-12-02 08:20:57 +00:00
|
|
|
maintainers = with maintainers; [ dit7ya ];
|
2024-02-29 20:09:43 +00:00
|
|
|
mainProgram = "motrix";
|
2022-12-02 08:20:57 +00:00
|
|
|
};
|
|
|
|
}
|