2021-02-05 17:12:51 +00:00
|
|
|
{ lib, buildGoModule, fetchFromGitHub, installShellFiles, nixosTests }:
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2020-09-25 04:45:31 +00:00
|
|
|
let
|
2020-04-24 23:36:52 +00:00
|
|
|
pname = "miniflux";
|
2022-08-21 13:32:41 +00:00
|
|
|
version = "2.0.38";
|
2020-09-25 04:45:31 +00:00
|
|
|
|
|
|
|
in buildGoModule {
|
|
|
|
inherit pname version;
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = pname;
|
2021-12-21 02:18:32 +00:00
|
|
|
repo = "v2";
|
2020-04-24 23:36:52 +00:00
|
|
|
rev = version;
|
2022-08-21 13:32:41 +00:00
|
|
|
sha256 = "sha256-y6g5HGIgEgb+Z26aKgj90oHIrXmrTmrpQyflKPOS0No=";
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
|
2022-08-21 13:32:41 +00:00
|
|
|
vendorSha256 = "sha256-ED4Rq+ks+75PdJvIye17eI7MLEJdP9yXHhbonqw2oMI=";
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2020-05-29 06:06:01 +00:00
|
|
|
nativeBuildInputs = [ installShellFiles ];
|
|
|
|
|
2021-02-05 17:12:51 +00:00
|
|
|
checkPhase = ''
|
|
|
|
go test $(go list ./... | grep -v client)
|
|
|
|
''; # skip client tests as they require network access
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2021-08-27 14:25:00 +00:00
|
|
|
ldflags = [
|
|
|
|
"-s" "-w" "-X miniflux.app/version.Version=${version}"
|
|
|
|
];
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
postInstall = ''
|
2020-05-15 21:57:56 +00:00
|
|
|
mv $out/bin/miniflux.app $out/bin/miniflux
|
2020-09-25 04:45:31 +00:00
|
|
|
installManPage miniflux.1
|
2020-04-24 23:36:52 +00:00
|
|
|
'';
|
|
|
|
|
2020-09-25 04:45:31 +00:00
|
|
|
passthru.tests = nixosTests.miniflux;
|
|
|
|
|
2021-01-15 22:18:51 +00:00
|
|
|
meta = with lib; {
|
2020-04-24 23:36:52 +00:00
|
|
|
description = "Minimalist and opinionated feed reader";
|
|
|
|
homepage = "https://miniflux.app/";
|
|
|
|
license = licenses.asl20;
|
|
|
|
maintainers = with maintainers; [ rvolosatovs benpye ];
|
|
|
|
};
|
|
|
|
}
|