diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 96f8bd9..6edcdbd 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -104,10 +104,12 @@ jobs: path: test-results release: - if: startsWith(github.event.ref, 'refs/tags/v') + # if: startsWith(github.event.ref, 'refs/tags/v') needs: [ui-test] # needs: [test, ui-test] runs-on: ubuntu-20.04 + permissions: + id-token: write # this permission is mandatory for trusted publishing steps: - uses: actions/download-artifact@v3 with: @@ -129,17 +131,7 @@ jobs: python -m pip install --upgrade pip pip install twine wheel jupyter-packaging jupyterlab - - name: Publish the Python package - env: - TWINE_USERNAME: __token__ - TWINE_PASSWORD: ${{ secrets.PYPI_API_TOKEN }} - run: twine upload --skip-existing dist/*.whl dist/*.tar.gz - - # - name: Publish the NPM package - # run: | - # echo $PRE_RELEASE - # if [[ $PRE_RELEASE == "true" ]]; then export TAG="next"; else export TAG="latest"; fi - # npm publish --tag ${TAG} --access public *.tgz - # env: - # NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }} - # PRE_RELEASE: ${{ github.event.release.prerelease }} + - name: Publish package distributions to PyPI + uses: pypa/gh-action-pypi-publish@release/v1 + with: + packages-dir: dist diff --git a/README.md b/README.md index ada204a..384fa30 100644 --- a/README.md +++ b/README.md @@ -29,7 +29,7 @@ The following components are wrapped (more will be coming): # Installation ``` -pip install ipyantd +pip install solara-ipyantd ``` # Dev install diff --git a/pyproject.toml b/pyproject.toml index 316cea5..56c2989 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -5,8 +5,11 @@ requires = [ ] build-backend = "hatchling.build" +[tool.hatch.build.targets.wheel] +packages = ["ipyantd"] + [project] -name = "ipyantd" +name = "solara-ipyantd" dynamic = ["version"] description = "React for ipywidgets that just works" readme = "README.md"