nur-packages

My NUR packages
git clone git://git.sikmir.ru/nur-packages
Log | Files | Refs | README | LICENSE

package.nix (1102B)


      1 {
      2   lib,
      3   fetchFromGitHub,
      4   fetchNpmDeps,
      5   python3Packages,
      6   nodejs,
      7   npmHooks,
      8 }:
      9 
     10 python3Packages.buildPythonPackage (finalAttrs: {
     11   pname = "ipyevents";
     12   version = "2.0.4";
     13   pyproject = true;
     14 
     15   __structuredAttrs = true;
     16 
     17   src = fetchFromGitHub {
     18     owner = "mwcraig";
     19     repo = "ipyevents";
     20     tag = finalAttrs.version;
     21     hash = "sha256-Fbtuw51luxKn9KxsW6dftnAHa2q9rpdaAvFi4mOFk0w=";
     22   };
     23 
     24   patches = [ ./package-lock.json.patch ];
     25 
     26   npmDeps = fetchNpmDeps {
     27     inherit (finalAttrs) src patches;
     28     hash = "sha256-CK9p0/G1yS7Msx1ieBEvjod+YsVbM8sLr/R3Gveve6I=";
     29   };
     30 
     31   build-system = with python3Packages; [
     32     hatchling
     33     hatch-jupyter-builder
     34     jupyterlab
     35   ];
     36 
     37   nativeBuildInputs = [
     38     nodejs
     39     npmHooks.npmConfigHook
     40   ];
     41 
     42   dependencies = with python3Packages; [
     43     ipywidgets
     44   ];
     45 
     46   pythonImportsCheck = [ "ipyevents" ];
     47 
     48   meta = {
     49     description = "A custom widget for returning mouse and keyboard events to Python";
     50     homepage = "https://github.com/mwcraig/ipyevents";
     51     license = lib.licenses.bsd3;
     52     maintainers = [ lib.maintainers.sikmir ];
     53   };
     54 })