2020-09-25 04:45:31 +00:00
|
|
|
{ lib
|
|
|
|
, buildPythonPackage
|
|
|
|
, fetchFromGitHub
|
2021-12-06 16:07:01 +00:00
|
|
|
, pythonOlder
|
2021-03-15 08:37:03 +00:00
|
|
|
, poetry-core
|
2020-09-25 04:45:31 +00:00
|
|
|
, textfsm
|
2024-04-21 15:54:59 +00:00
|
|
|
, invoke
|
2020-09-25 04:45:31 +00:00
|
|
|
, pytestCheckHook
|
2021-12-06 16:07:01 +00:00
|
|
|
, ruamel-yaml
|
2024-04-21 15:54:59 +00:00
|
|
|
, toml
|
2020-09-25 04:45:31 +00:00
|
|
|
, yamllint
|
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "ntc-templates";
|
2024-04-21 15:54:59 +00:00
|
|
|
version = "4.4.0";
|
2021-03-15 08:37:03 +00:00
|
|
|
format = "pyproject";
|
2021-12-06 16:07:01 +00:00
|
|
|
|
2023-10-09 19:29:22 +00:00
|
|
|
disabled = pythonOlder "3.7";
|
2020-09-25 04:45:31 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "networktocode";
|
|
|
|
repo = pname;
|
2023-01-20 10:41:00 +00:00
|
|
|
rev = "refs/tags/v${version}";
|
2024-04-21 15:54:59 +00:00
|
|
|
hash = "sha256-8Lzh6ku2TUQFatqbOb5JIc/WkRPegx/gNnT53DErMuk=";
|
2020-09-25 04:45:31 +00:00
|
|
|
};
|
|
|
|
|
2021-03-15 08:37:03 +00:00
|
|
|
nativeBuildInputs = [
|
|
|
|
poetry-core
|
|
|
|
];
|
2020-09-25 04:45:31 +00:00
|
|
|
|
2021-03-15 08:37:03 +00:00
|
|
|
propagatedBuildInputs = [
|
|
|
|
textfsm
|
|
|
|
];
|
|
|
|
|
2023-02-02 18:25:31 +00:00
|
|
|
nativeCheckInputs = [
|
2024-04-21 15:54:59 +00:00
|
|
|
invoke
|
2021-03-15 08:37:03 +00:00
|
|
|
pytestCheckHook
|
2021-12-06 16:07:01 +00:00
|
|
|
ruamel-yaml
|
2024-04-21 15:54:59 +00:00
|
|
|
toml
|
2021-03-15 08:37:03 +00:00
|
|
|
yamllint
|
|
|
|
];
|
2020-09-25 04:45:31 +00:00
|
|
|
|
|
|
|
# https://github.com/networktocode/ntc-templates/issues/743
|
2021-03-15 08:37:03 +00:00
|
|
|
disabledTests = [
|
|
|
|
"test_raw_data_against_mock"
|
|
|
|
"test_verify_parsed_and_reference_data_exists"
|
|
|
|
];
|
2020-09-25 04:45:31 +00:00
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
description = "TextFSM templates for parsing show commands of network devices";
|
|
|
|
homepage = "https://github.com/networktocode/ntc-templates";
|
2023-10-09 19:29:22 +00:00
|
|
|
changelog = "https://github.com/networktocode/ntc-templates/releases/tag/v${version}";
|
2020-09-25 04:45:31 +00:00
|
|
|
license = licenses.asl20;
|
2024-01-13 08:15:51 +00:00
|
|
|
maintainers = with maintainers; [ ];
|
2020-09-25 04:45:31 +00:00
|
|
|
};
|
|
|
|
}
|