diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 687b66b..4c00a67 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -47,3 +47,33 @@ jobs: # uses: codecov/codecov-action@v4.0.1 # with: # token: ${{ secrets.CODECOV_TOKEN }} + + publish: + runs-on: ubuntu-latest + + # Steps for running tests and analysis. + steps: + - name: Checking out repository + uses: actions/checkout@v4 + with: + token: ${{ secrets.GITHUB_TOKEN }} + submodules: recursive + + - name: Install a specific version of uv + uses: astral-sh/setup-uv@v3 + with: + version: "0.4.x" + enable-cache: true + + - name: Install Python 3.12 + run: uv python install 3.12 + + - name: Build package + run: uv build + + - name: Check package can be imported + run: uv run --with dist/dtspy-*-py3-none-any.whl --no-project -- python -c "import dts" + + # when ready to upload to PyPI + # name: upload to PyPI + # run: uv publish