python3Packages.yamlfix: init at 0.7.2

This commit is contained in:
Jan van den Berg
2021-12-23 09:03:44 -08:00
committed by Jonathan Ringer
parent ef947d0bae
commit f0660ce159
3 changed files with 40 additions and 0 deletions
@@ -0,0 +1,36 @@
{ lib, buildPythonPackage, fetchFromGitHub, pytestCheckHook, pytest-xdist
, pythonOlder, click, ruyaml }:
buildPythonPackage rec {
pname = "yamlfix";
version = "0.7.2";
disabled = pythonOlder "3.7";
src = fetchFromGitHub {
owner = "lyz-code";
repo = pname;
rev = version;
sha256 = "sha256-qlA6TyLkOuTXCdMnpfkyN/HDIRfB6+0pQ7f0GCsIjL4=";
};
propagatedBuildInputs = [ click ruyaml ];
checkInputs = [ pytestCheckHook pytest-xdist ];
postPatch = ''
substituteInPlace pyproject.toml \
--replace 'python_paths = "."' ""
'';
pytestFlagsArray = [ "-n" "$NIX_BUILD_CORES" ];
pythonImportsCheck = [ "yamlfix" ];
meta = with lib; {
description =
"A simple opinionated yaml formatter that keeps your comments!";
homepage = "https://github.com/lyz-code/yamlfix";
license = licenses.gpl3Plus;
maintainers = with maintainers; [ koozz ];
};
}
+2
View File
@@ -11175,6 +11175,8 @@ with pkgs;
yank = callPackage ../tools/misc/yank { };
yamlfix = with python3Packages; toPythonApplication yamlfix;
yamllint = with python3Packages; toPythonApplication yamllint;
yaml-merge = callPackage ../tools/text/yaml-merge { };
+2
View File
@@ -10397,6 +10397,8 @@ in {
yamale = callPackage ../development/python-modules/yamale { };
yamlfix = callPackage ../development/python-modules/yamlfix { };
yamllint = callPackage ../development/python-modules/yamllint { };
yamlloader = callPackage ../development/python-modules/yamlloader { };