Skip to content

Commit

Permalink
build: Exclude tests in sdist to reduce size
Browse files Browse the repository at this point in the history
* See https://github.com/mwouts/jupytext/pull/1140/files#r1364945854

* Remove unnecessary env var in binder postbuild
  • Loading branch information
mahendrapaipuri committed Oct 19, 2023
1 parent 270feec commit 3086161
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 deletions.
2 changes: 1 addition & 1 deletion binder/postBuild
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ set -e
# Install from sources
# NB: If you want to use Jupytext on your binder, don't install it from source,
# just add "jupytext" to your "binder/requirements.txt" instead.
HATCH_BUILD_HOOKS_ENABLE=true pip install .
pip install .

mkdir -p ${HOME}/.jupyter/labconfig
cp binder/labconfig/* ${HOME}/.jupyter/labconfig
Expand Down
6 changes: 4 additions & 2 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ dynamic = ["version"]
[project.urls]
Homepage = "https://github.com/mwouts/jupytext"
"Source Code" = "https://github.com/mwouts/jupytext"
Documentation = "https://jupytext.readthedocs.io/en/latest/index.html"
Documentation = "https://jupytext.readthedocs.io"

[project.optional-dependencies]
# Test related dependencies
Expand Down Expand Up @@ -102,10 +102,12 @@ path = "src/jupytext/version.py"
# Following config is related to JupyterLab extension
[tool.hatch.build.targets.sdist]
artifacts = ["jupyterlab/jupyterlab_jupytext/labextension"]
# Exclude tests (contains Notebooks that have a total size of ~8MB) to reduce sdist
# tarball. (See #1142)
exclude = ["tests", "**/.yarn", "**/node_modules"]

[tool.hatch.build.targets.wheel]
packages = ["src/jupytext", "src/jupytext_config", "jupyterlab/jupyterlab_jupytext"]
exclude = ["**/.yarn", "**/node_modules"]

[tool.hatch.build.targets.wheel.shared-data]
"jupyterlab/jupyter-config" = "etc/jupyter"
Expand Down

0 comments on commit 3086161

Please sign in to comment.