pkgs/vpython-jupyter: init with dependencies

This commit is contained in:
Infinidoge 2025-01-19 13:56:07 -05:00
parent e2f89e5e16
commit 903800fb0b
Signed by: Infinidoge
SSH key fingerprint: SHA256:EMoPe5e2dO0gEvtBb2xkZTz5dkyL0rBmuiGTKG5s96E
8 changed files with 9298 additions and 2 deletions

View file

@ -0,0 +1,66 @@
{ buildPythonPackage
, fetchFromGitHub
, yarnConfigHook
, fetchYarnDeps
, jupyterlab
, jupyter
, jupyter-packaging
, hatchling
, hatch-jupyter-builder
, hatch-nodejs-version
, nodejs
}:
buildPythonPackage rec {
pname = "jupyterlab-vpython";
version = "0-unstable-2024-03-10";
pyproject = true;
src = fetchFromGitHub {
owner = "jcoady";
repo = "jupyterlab_vpython";
rev = "6a217306bb3fea48cb04ae0e6980b871bae5c626";
hash = "sha256-yST604b5UAk+vPb0R8weI+ufuZFQTr6+MYUkX013s6I=";
};
yarnOfflineCache = fetchYarnDeps {
yarnLock = ./yarn.lock;
hash = "sha256-/t97A2uUjtas7KBQXaK+lm0GXAtHOlT976G/qQpKN1Y=";
};
nativeBuildInputs = [
yarnConfigHook
nodejs
];
build-system = [
hatchling
hatch-jupyter-builder
hatch-nodejs-version
jupyterlab
jupyter
jupyter-packaging
];
dependencies = [
jupyterlab
jupyter
jupyter-packaging
];
prePatch = ''
cp ${./yarn.lock} yarn.lock
'';
preConfigure = ''
substituteInPlace package.json \
--replace-fail 'jlpm' 'yarn'
'';
preBuild = ''
# Generate the jupyterlab extension files
yarn --offline run build:prod
'';
}

File diff suppressed because it is too large Load diff