Files
nixpkgs/pkgs/development/python-modules/jupyterlab-pygments/default.nix
T
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

51 lines
1.0 KiB
Nix

{
lib,
buildPythonPackage,
fetchPypi,
pythonOlder,
hatch-jupyter-builder,
hatch-nodejs-version,
hatchling,
pygments,
}:
buildPythonPackage rec {
pname = "jupyterlab-pygments";
version = "0.3.0";
pyproject = true;
disabled = pythonOlder "3.8";
src = fetchPypi {
pname = "jupyterlab_pygments";
inherit version;
hash = "sha256-chrKTZApJSsRz6nRheW1r01Udyu4By+bcDb0FwBU010=";
};
# jupyterlab is not necessary since we get the source from pypi
postPatch = ''
substituteInPlace pyproject.toml \
--replace '"jupyterlab>=4.0.0,<5",' ""
'';
nativeBuildInputs = [
hatch-jupyter-builder
hatch-nodejs-version
hatchling
];
# no tests exist on upstream repo
doCheck = false;
propagatedBuildInputs = [ pygments ];
pythonImportsCheck = [ "jupyterlab_pygments" ];
meta = {
description = "Jupyterlab syntax coloring theme for pygments";
homepage = "https://github.com/jupyterlab/jupyterlab_pygments";
license = lib.licenses.bsd3;
maintainers = [ ];
};
}