2021-01-11 08:54:33 +01:00
|
|
|
{ lib, stdenv, fetchFromGitHub, uget, python3Packages }:
|
2018-04-30 04:41:36 +02:00
|
|
|
|
|
|
|
stdenv.mkDerivation rec {
|
2019-08-15 14:41:18 +02:00
|
|
|
pname = "uget-integrator";
|
2018-04-30 04:41:36 +02:00
|
|
|
version = "1.0.0";
|
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "ugetdm";
|
|
|
|
repo = "uget-integrator";
|
|
|
|
rev = "v${version}";
|
|
|
|
sha256 = "0bfqwbpprxp5sy49p2hqcjdfj7zamnp2hhcnnyccffkn7pghx8pp";
|
|
|
|
};
|
|
|
|
|
|
|
|
nativeBuildInputs = [ python3Packages.wrapPython ];
|
|
|
|
|
|
|
|
buildInputs = [ uget python3Packages.python ];
|
|
|
|
|
|
|
|
installPhase = ''
|
|
|
|
for f in conf/com.ugetdm.{chrome,firefox}.json; do
|
|
|
|
substituteInPlace $f --replace "/usr" "$out"
|
|
|
|
done
|
|
|
|
|
2021-01-20 00:45:29 +01:00
|
|
|
install -D -t $out/bin bin/uget-integrator
|
|
|
|
install -D -t $out/etc/opt/chrome/native-messaging-hosts conf/com.ugetdm.chrome.json
|
|
|
|
install -D -t $out/etc/chromium/native-messaging-hosts conf/com.ugetdm.chrome.json
|
|
|
|
install -D -t $out/etc/opera/native-messaging-hosts conf/com.ugetdm.chrome.json
|
|
|
|
install -D -t $out/lib/mozilla/native-messaging-hosts conf/com.ugetdm.firefox.json
|
2018-04-30 04:41:36 +02:00
|
|
|
|
|
|
|
wrapPythonPrograms
|
|
|
|
'';
|
|
|
|
|
2021-01-11 08:54:33 +01:00
|
|
|
meta = with lib; {
|
2018-04-30 04:41:36 +02:00
|
|
|
description = "Native messaging host to integrate uGet Download Manager with web browsers";
|
2020-04-01 03:11:51 +02:00
|
|
|
homepage = "https://github.com/ugetdm/uget-integrator";
|
2018-04-30 04:41:36 +02:00
|
|
|
license = licenses.gpl3;
|
|
|
|
platforms = platforms.linux;
|
|
|
|
maintainers = [ maintainers.romildo ];
|
|
|
|
};
|
|
|
|
}
|