blob: 451af0cd10c978f7d439ffb2cbab61ebed9fde85 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
|
{
lib,
stdenv,
fetchFromGitHub,
rustPlatform,
clippy,
sarif-fmt,
testers,
}:
rustPlatform.buildRustPackage rec {
pname = "sarif-fmt";
version = "0.4.2";
src = fetchFromGitHub {
owner = "psastras";
repo = "sarif-rs";
rev = "${pname}-v${version}";
hash = "sha256-EzWzDeIeSJ11CVcVyAhMjYQJcKHnieRrFkULc5eXAno=";
};
cargoSha256 = "sha256-dHOxVLXtnqSHMX5r1wFxqogDf9QdnOZOjTyYFahru34=";
cargoBuildFlags = ["--package" pname];
cargoTestFlags = cargoBuildFlags;
nativeCheckInputs = lib.optionals stdenv.isLinux [
# test_clippy
clippy
];
checkFlags =
[
# this test uses nix so...no go
"--skip=test_clang_tidy"
# ditto
"--skip=test_hadolint"
# ditto
"--skip=test_shellcheck"
]
++ lib.optionals stdenv.isDarwin [
"--skip=test_clippy"
];
passthru = {
tests.version = testers.testVersion {
package = sarif-fmt;
};
};
meta = with lib; {
mainProgram = "sarif-fmt";
description = "A CLI tool to pretty print SARIF diagnostics";
homepage = "https://psastras.github.io/sarif-rs";
maintainers = with maintainers; [getchoo];
license = licenses.mit;
};
}
|