diff --git a/.github/workflows/update_licenses.yml b/.github/workflows/update_licenses.yml index 64fc9f043..8d98d994b 100644 --- a/.github/workflows/update_licenses.yml +++ b/.github/workflows/update_licenses.yml @@ -17,6 +17,23 @@ jobs: with: python-version: "3.10" + - name: Bootstrap poetry + run: | + curl -sSL https://install.python-poetry.org | python - -y + + - name: Update PATH + run: echo "$HOME/.local/bin" >> $GITHUB_PATH + + - name: Configure poetry + run: poetry config virtualenvs.in-project true + + - name: Install dependencies + run: poetry install + + - name: Update licenses list + run: | + poetry run python src/poetry/core/spdx/helpers.py + - name: Generate token id: generate_token uses: tibdex/github-app-token@v1 @@ -24,10 +41,6 @@ jobs: app_id: ${{ secrets.POETRY_TOKEN_APP_ID }} private_key: ${{ secrets.POETRY_TOKEN_APP_KEY }} - - name: Update licenses list - run: | - python src/poetry/core/spdx/helpers.py - - name: Create PR if necessary uses: peter-evans/create-pull-request@v5 with: