depot/third_party/nixpkgs/pkgs/development/python-modules/yamllint/default.nix
Default email bba55970ba Project import generated by Copybara.
GitOrigin-RevId: 3d1a7716d7f1fccbd7d30ab3b2ed3db831f43bde
2021-04-05 17:23:46 +02:00

48 lines
1 KiB
Nix

{ lib
, buildPythonPackage
, fetchPypi
, pathspec
, pytestCheckHook
, pythonOlder
, pyyaml
, stdenv
}:
buildPythonPackage rec {
pname = "yamllint";
version = "1.26.0";
disabled = pythonOlder "3.5";
src = fetchPypi {
inherit pname version;
sha256 = "11qhs1jk9pwvyk5k3q5blh9sq42dh1ywdf1f3i2zixf7hncwir5h";
};
propagatedBuildInputs = [
pyyaml
pathspec
];
checkInputs = [
pytestCheckHook
];
disabledTests = [
# test failure reported upstream: https://github.com/adrienverge/yamllint/issues/373
"test_find_files_recursively"
] ++ lib.optional stdenv.isDarwin [
# locale tests are broken on BSDs; see https://github.com/adrienverge/yamllint/issues/307
"test_locale_accents"
"test_locale_case"
"test_run_with_locale"
];
pythonImportsCheck = [ "yamllint" ];
meta = with lib; {
description = "A linter for YAML files";
homepage = "https://github.com/adrienverge/yamllint";
license = licenses.gpl3Plus;
maintainers = with maintainers; [ jonringer mikefaille ];
};
}