mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-11-29 18:33:00 +00:00
2641d97cbf
Reproduction script: # Bulk rewrite ./maintainers/scripts/sha-to-sri.py pkgs/by-name # Revert some packages which will need manual intervention for n in amdvlk azure-cli cargo-profiler corefonts flatito fluxcd gist perf_data_converter protoc-gen-js solana-cli swt verible; do git checkout -- "pkgs/by-name/${n:0:2}/${n}" done
42 lines
917 B
Nix
42 lines
917 B
Nix
{ lib
|
|
, buildGoModule
|
|
, fetchFromGitHub
|
|
, tetex
|
|
, makeWrapper
|
|
}:
|
|
buildGoModule rec {
|
|
pname = "reporter";
|
|
version = "2.3.1";
|
|
|
|
src = fetchFromGitHub {
|
|
rev = "v${version}";
|
|
owner = "IzakMarais";
|
|
repo = "reporter";
|
|
hash = "sha256-lsraJwx56I2Gn8CePWUlQu1qdMp78P4xwPzLxetYUcw=";
|
|
};
|
|
|
|
nativeBuildInputs = [ makeWrapper ];
|
|
|
|
vendorHash = null;
|
|
|
|
postPatch = ''
|
|
go mod init github.com/IzakMarais/reporter
|
|
'';
|
|
|
|
postInstall = ''
|
|
wrapProgram $out/bin/grafana-reporter \
|
|
--prefix PATH : ${lib.makeBinPath [ tetex ]}
|
|
'';
|
|
|
|
# Testing library used had a breaking API change and upstream didn't adapt.
|
|
doCheck = false;
|
|
|
|
meta = {
|
|
description = "PDF report generator from a Grafana dashboard";
|
|
mainProgram = "grafana-reporter";
|
|
homepage = "https://github.com/IzakMarais/reporter";
|
|
license = lib.licenses.mit;
|
|
maintainers = [ lib.maintainers.disassembler ];
|
|
};
|
|
}
|