From fab89dda1d0979e38ae03be415ba75980666ac4e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Joa=CC=83o=20Male=CC=81s?= Date: Tue, 24 Sep 2024 14:50:09 +0100 Subject: [PATCH] Revert "Update release.yaml" This reverts commit ec9330149648746dbd1fc0123b50edb11a919488. --- .github/workflows/release.yaml | 22 +++++++--------------- 1 file changed, 7 insertions(+), 15 deletions(-) diff --git a/.github/workflows/release.yaml b/.github/workflows/release.yaml index 52921c33..8d20ebed 100644 --- a/.github/workflows/release.yaml +++ b/.github/workflows/release.yaml @@ -18,42 +18,34 @@ jobs: FOLDERS_JSON=$(find . -maxdepth 1 -type d -name "thousandeyes-sdk-*" | cut -c 3- | jq -R -s -c 'split("\n")[:-1]') echo "packages=$FOLDERS_JSON" >> "$GITHUB_OUTPUT" deployment: - #if: github.event.pull_request.merged == true + if: github.event.pull_request.merged == true needs: set-package-matrix strategy: - fail-fast: false matrix: - package-name: [thousandeyes-sdk-administrative, thousandeyes-sdk-instant-tests, thousandeyes-sdk-usage, thousandeyes-sdk-core] + package-name: ${{ fromJSON(needs.set-package-matrix.outputs.packages) }} runs-on: ubuntu-latest permissions: id-token: write environment: - name: test - url: https://test.pypi.org/p/${{ matrix.package-name }} + name: release + url: https://pypi.org/p/${{ matrix.package-name }} steps: - uses: actions/checkout@v4 - with: - ref: main - python-version: '3.11' - token: ${{ secrets.TEST_PAT }} - name: Set up Python uses: actions/setup-python@v5 with: cache: pip - python-version: '3.11' cache-dependency-path: '**/pyproject.toml' - name: Install dependencies run: | pip install setuptools wheel build - name: Build run: | - echo "$GITHUB_REF_NAME" >> ${{ matrix.package-name }}/.version - - ls ${{ matrix.package-name }}/ - cp LICENSE NOTICE ${{ matrix.package-name }}/ + echo $GITHUB_REF_NAME >> ${{ matrix.package-name }}/.version + cp LICENSE NOTICE ${{ matrix.package-name }}/ python -m build ${{ matrix.package-name }} --outdir dist/ - name: Publish uses: pypa/gh-action-pypi-publish@release/v1 with: - repository-url: https://test.pypi.org/legacy/ skip-existing: true +