Merge pull request #307098 from r-ryantm/auto-update/cilium-cli
[NixPkgs.git] / pkgs / development / python-modules / cwlformat / default.nix
blob0703175d02752c934e7d33c0da4fb5f493dd1868
1 { lib
2 , buildPythonPackage
3 , fetchFromGitHub
4 , fetchpatch
5 , pytestCheckHook
6 , pythonOlder
7 , ruamel-yaml
8 }:
10 buildPythonPackage rec {
11   pname = "cwlformat";
12   version = "2022.02.18";
13   format = "setuptools";
15   disabled = pythonOlder "3.8";
17   src = fetchFromGitHub {
18     owner = "rabix";
19     repo = "cwl-format";
20     rev = "refs/tags/${version}";
21     hash = "sha256-FI8hUgb/KglTkubZ+StzptoSsYal71ITyyFNg7j48yk=";
22   };
24   patches = [
25     # https://github.com/rabix/cwl-format/pull/21
26     (fetchpatch {
27       name = "fix-for-ruamel-yaml-0.17.23.patch";
28       url = "https://github.com/rabix/cwl-format/commit/9d54330c73c454d2ccacd55e2d51a4145f282041.patch";
29       hash = "sha256-TZGK7T2gzxMvreCLtl3nkuPrqL2KzgrO3yCNmd5lY3g=";
30     })
31   ];
33   propagatedBuildInputs = [
34     ruamel-yaml
35   ];
37   nativeCheckInputs = [
38     pytestCheckHook
39   ];
41   pythonImportsCheck = [
42     "cwlformat"
43   ];
45   meta = with lib; {
46     description = "Code formatter for CWL";
47     homepage = "https://github.com/rabix/cwl-format";
48     changelog = "https://github.com/rabix/cwl-format/releases/tag/${version}";
49     license = licenses.asl20;
50     maintainers = with maintainers; [ fab ];
51   };