diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml index fcdd379..33a84ec 100644 --- a/.github/workflows/publish.yml +++ b/.github/workflows/publish.yml @@ -31,10 +31,15 @@ jobs: with: path: ~/.local key: poetry-${{ runner.os }}-${{ env.POETRY_VERSION }}-${{ steps.setup-python.outputs.python-version }} - - name: Expect Poetry cached - id: expect-cached-poetry + - name: Install Poetry + id: install-poetry if: steps.cached-poetry.outputs.cache-hit != 'true' - run: echo "Expected cached Poetry installation, but it was not found." && exit 1 + uses: snok/install-poetry@v1 + with: + version: ${{ env.POETRY_VERSION }} + virtualenvs-create: true + virtualenvs-in-project: true + installer-parallel: true - name: Poetry git plugin run: poetry self add poetry-git-version-plugin - name: Load cached venv @@ -43,9 +48,6 @@ jobs: with: path: .venv key: venv-${{ runner.os }}-${{ steps.setup-python.outputs.python-version }}-${{ hashFiles('**/poetry.lock') }} - - name: Expect environment cached - if: steps.cached-poetry-dependencies.outputs.cache-hit != 'true' - run: echo "Expected cached environment, but it was not found." && exit 1 - name: Poetry Build run: poetry build -v