nixpkgs/pkgs/servers/libreddit/default.nix
2022-11-01 08:50:43 +01:00

35 lines
751 B
Nix

{ lib
, stdenv
, nixosTests
, rustPlatform
, fetchFromGitHub
, Security
}:
rustPlatform.buildRustPackage rec {
pname = "libreddit";
version = "0.23.1";
src = fetchFromGitHub {
owner = "spikecodes";
repo = pname;
rev = "v${version}";
sha256 = "sha256-qO9AgEAm+wK8LAlUOYIKYTXJYT3yz65UWAFTf711+5w=";
};
cargoSha256 = "sha256-ApZLYKavYt1Zp7qvdbhBXPBj7qv/D/oZp5lK2sfWnDI=";
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 ];
maintainers = with maintainers; [ fab jojosch ];
};
}