ansible-cmdb: init at 1.31

+101
+60
pkgs/by-name/an/ansible-cmdb/package.nix
··· 1 + { 2 + lib, 3 + fetchFromGitHub, 4 + substituteAll, 5 + python3Packages, 6 + testers, 7 + ansible-cmdb, 8 + }: 9 + let 10 + inherit (python3Packages) 11 + setuptools 12 + mako 13 + pyyaml 14 + jsonxs 15 + buildPythonApplication 16 + ; 17 + 18 + pname = "ansible-cmdb"; 19 + version = "1.31"; 20 + in 21 + buildPythonApplication { 22 + inherit pname version; 23 + 24 + pyproject = true; 25 + 26 + src = fetchFromGitHub { 27 + owner = "fboender"; 28 + repo = "ansible-cmdb"; 29 + rev = version; 30 + hash = "sha256-HOFLX8fiid+xJOVYNyVbz5FunrhteAUPlvS3ctclVHo="; 31 + }; 32 + 33 + patches = [ 34 + (substituteAll { 35 + src = ./setup.patch; 36 + inherit version; 37 + }) 38 + ]; 39 + 40 + build-system = [ setuptools ]; 41 + 42 + dependencies = [ 43 + mako 44 + pyyaml 45 + jsonxs 46 + ]; 47 + 48 + passthru.tests.version = testers.testVersion { 49 + package = ansible-cmdb; 50 + version = "v${version}"; 51 + }; 52 + 53 + meta = { 54 + description = "Generate host overview from ansible fact gathering output"; 55 + homepage = "https://github.com/fboender/ansible-cmdb"; 56 + license = lib.licenses.gpl3Only; 57 + maintainers = [ lib.maintainers.tie ]; 58 + mainProgram = "ansible-cmdb"; 59 + }; 60 + }
+41
pkgs/by-name/an/ansible-cmdb/setup.patch
··· 1 + diff --git a/src/ansible-cmdb.py b/bin/ansible-cmdb 2 + similarity index 100% 3 + rename from src/ansible-cmdb.py 4 + rename to bin/ansible-cmdb 5 + diff --git a/setup.py b/setup.py 6 + index a8db25d..c1670f1 100755 7 + --- a/setup.py 8 + +++ b/setup.py 9 + @@ -42,17 +42,16 @@ setup( 10 + package_dir={'': 'src'}, 11 + packages=find_packages('src'), 12 + include_package_data=True, 13 + - data_files=\ 14 + - get_data_files( 15 + - 'src/ansiblecmdb/data', 16 + - strip='src', 17 + - prefix='lib' 18 + - ) + 19 + - [['lib/ansiblecmdb/', ['src/ansible-cmdb.py']]], 20 + + data_files=get_data_files( 21 + + 'src/ansiblecmdb/data', 22 + + strip='src', 23 + + prefix='lib', 24 + + ), 25 + zip_safe=False, 26 + - install_requires=['mako', 'pyyaml', 'ushlex', 'jsonxs'], 27 + + install_requires=['mako', 'pyyaml'], 28 + + extras_require={'jsonxs_templates': ['jsonxs']}, 29 + scripts=[ 30 + - 'src/ansible-cmdb', 31 + + 'bin/ansible-cmdb', 32 + ], 33 + 34 + classifiers=[ 35 + diff --git a/src/ansiblecmdb/data/VERSION b/src/ansiblecmdb/data/VERSION 36 + index 79d94e6..14d2ff6 100644 37 + --- a/src/ansiblecmdb/data/VERSION 38 + +++ b/src/ansiblecmdb/data/VERSION 39 + @@ -1 +1 @@ 40 + -MASTER 41 + +@version@