diff --git a/projects/vdk-plugins/vdk-jupyter/.plugin-ci.yml b/projects/vdk-plugins/vdk-jupyter/.plugin-ci.yml index 9c55d9677b..4416e0e83f 100644 --- a/projects/vdk-plugins/vdk-jupyter/.plugin-ci.yml +++ b/projects/vdk-plugins/vdk-jupyter/.plugin-ci.yml @@ -31,3 +31,25 @@ build-vdk-jupyterlab-extension: - if: '$CI_COMMIT_BRANCH == "main" || $CI_PIPELINE_SOURCE == "external_pull_request_event"' changes: - "projects/vdk-plugins/vdk-jupyter/**/*" + + +release-vdk-jupyter: + variables: + PLUGIN_NAME: + image: "python:3.10-alpine" + stage: release + before_script: + - export VDK_PATCH_VERSION=${CI_PIPELINE_ID} + script: + - cd projects/vdk-plugins/vdk-jupyter/vdk-jupyterlab-extension/ || exit 1 + - apk --no-cache add npm rust cargo libffi-dev + - pip install -U pip setuptools wheel twine pre-commit build hatch jupyter + - hatch version 0.1.$VDK_PATCH_VERSION + - python -m build + - twine upload --repository-url $PIP_REPO_UPLOAD_URL -u "$PIP_REPO_UPLOAD_USER_NAME" -p "$PIP_REPO_UPLOAD_USER_PASSWORD" dist/* --verbose + rules: + - if: '$CI_PIPELINE_SOURCE == "schedule"' + when: never + - if: '$CI_COMMIT_BRANCH == "main"' + changes: + - "projects/vdk-plugins/vdk-jupyter/**/*" diff --git a/projects/vdk-plugins/vdk-jupyter/vdk-jupyterlab-extension/README.md b/projects/vdk-plugins/vdk-jupyter/vdk-jupyterlab-extension/README.md index 8dd953b806..9b491c9015 100644 --- a/projects/vdk-plugins/vdk-jupyter/vdk-jupyterlab-extension/README.md +++ b/projects/vdk-plugins/vdk-jupyter/vdk-jupyterlab-extension/README.md @@ -14,16 +14,13 @@ for the frontend extension. - Versatile Data Kit - npm -## Install - -To install the extension,first navigate to the project directory and then execute: +## Install and run ```bash -# Once in the project directory, use the npm ci command to install -# the exact versions of the dependencies specified in the package-lock.json -npm ci -# Install the extension +# install the extension pip install vdk-jupyterlab-extension +# run jupyterlab +jupyter lab ``` ## Uninstall diff --git a/projects/vdk-plugins/vdk-jupyter/vdk-jupyterlab-extension/pyproject.toml b/projects/vdk-plugins/vdk-jupyter/vdk-jupyterlab-extension/pyproject.toml index 43d6e8a503..facd5044a1 100644 --- a/projects/vdk-plugins/vdk-jupyter/vdk-jupyterlab-extension/pyproject.toml +++ b/projects/vdk-plugins/vdk-jupyter/vdk-jupyterlab-extension/pyproject.toml @@ -23,7 +23,10 @@ classifiers = [ "Programming Language :: Python :: 3.11", ] dependencies = [ - "jupyter_server>=1.6,<3" + "jupyter_server>=1.6,<3", + "jupyterlab==3.6.3", + "vdk-control-cli", + "vdk-core" ] dynamic = ["version", "description", "authors", "urls", "keywords"] diff --git a/projects/vdk-plugins/vdk-jupyter/vdk-jupyterlab-extension/setup.py b/projects/vdk-plugins/vdk-jupyter/vdk-jupyterlab-extension/setup.py deleted file mode 100644 index 2d33651683..0000000000 --- a/projects/vdk-plugins/vdk-jupyter/vdk-jupyterlab-extension/setup.py +++ /dev/null @@ -1,4 +0,0 @@ -# Copyright 2021-2023 VMware, Inc. -# SPDX-License-Identifier: Apache-2.0 - -__import__("setuptools").setup()