nixpkgs/pkgs/development/python-modules/netbox-floorplan-plugin/default.nix
Ihar Hrachyshka 567e8dfd8e
treewide: clean up 'meta = with' pattern
This commit was created by a combination of scripts and tools:
- an ast-grep script to prefix things in meta with `lib.`,
- a modified nixf-diagnose / nixf combination to remove unused `with
lib;`, and
- regular nixfmt.

Co-authored-by: Wolfgang Walther <walther@technowledgy.de>
2025-12-10 18:09:49 +01:00

46 lines
1.1 KiB
Nix

{
lib,
buildPythonPackage,
fetchFromGitHub,
setuptools,
netbox,
django,
netaddr,
python,
}:
buildPythonPackage rec {
pname = "netbox-floorplan-plugin";
version = "0.8.0";
pyproject = true;
disabled = python.pythonVersion != netbox.python.pythonVersion;
src = fetchFromGitHub {
owner = "netbox-community";
repo = "netbox-floorplan-plugin";
tag = version;
hash = "sha256-27rVf3b1MNiTil+yx+PWtf6CzQ24oyCqLgeoYUje14o=";
};
build-system = [ setuptools ];
nativeCheckInputs = [
netbox
django
netaddr
];
preFixup = ''
export PYTHONPATH=${netbox}/opt/netbox/netbox:$PYTHONPATH
'';
pythonImportsCheck = [ "netbox_floorplan" ];
meta = {
description = "Netbox plugin providing floorplan mapping capability for locations and sites";
homepage = "https://github.com/netbox-community/netbox-floorplan-plugin";
changelog = "https://github.com/netbox-community/netbox-floorplan-plugin/releases/tag/${src.tag}";
license = lib.licenses.lgpl3;
maintainers = with lib.maintainers; [ cobalt ];
};
}