2021-04-11 21:37:30 +00:00
|
|
|
{ lib
|
|
|
|
, stdenv
|
|
|
|
, nixosTests
|
|
|
|
, rustPlatform
|
|
|
|
, fetchFromGitHub
|
|
|
|
, Security
|
|
|
|
}:
|
|
|
|
|
|
|
|
rustPlatform.buildRustPackage rec {
|
|
|
|
pname = "libreddit";
|
2022-05-16 07:04:37 +00:00
|
|
|
version = "0.22.7";
|
2021-04-11 21:37:30 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "spikecodes";
|
|
|
|
repo = pname;
|
|
|
|
rev = "v${version}";
|
2022-05-16 07:04:37 +00:00
|
|
|
sha256 = "sha256-kM+XvkSxc+OsHq2hGPdpy32jQ/35AJo75PlpbeWjef0=";
|
2021-04-11 21:37:30 +00:00
|
|
|
};
|
|
|
|
|
2022-05-16 07:04:37 +00:00
|
|
|
cargoSha256 = "sha256-md56axw3tpl++wP3ga0iMX63ixu/35lhT4TA2Uo8GpI=";
|
2021-04-11 21:37:30 +00:00
|
|
|
|
|
|
|
buildInputs = lib.optional stdenv.isDarwin Security;
|
|
|
|
|
|
|
|
passthru.tests = {
|
|
|
|
inherit (nixosTests) libreddit;
|
|
|
|
};
|
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
description = "Private front-end for Reddit";
|
|
|
|
homepage = "https://github.com/spikecodes/libreddit";
|
|
|
|
license = with licenses; [ agpl3Only ];
|
2021-12-30 07:25:38 +00:00
|
|
|
maintainers = with maintainers; [ fab jojosch ];
|
2021-04-11 21:37:30 +00:00
|
|
|
};
|
|
|
|
}
|