This extension can be distributed as Python packages. All of the Python packaging instructions in the pyproject.toml
file to wrap your extension in a Python package. Before generating a package, we first need to install build
.
pip install build twine
- package.json
- package-lock.json
- pgljupyter/_frontend.py
- pgljupyter/_version.py
- version
- API spec
- descriptions
Activate conda dev env and emsdk e.g.
conda activate pgljupyter-dev
source ~/emsdk/emsdk_env.sh
You need build and twine installed. To create a Python source package (.tar.gz
) and the binary package (.whl
) in the dist/
directory, do:
npm run build:prod
python -m build
Make sure there are no old/oudated files in dist/ Then to upload the package to PyPI, do:
twine upload dist/pgljupyter-*
Mainly for tools like nbviewer or vscode that load widgets from the npm package.
npm login
npm publish
git push
git tag -a v{version} -m "v{version}"
git push --tags