From 192395c0d10c082a7c62294ab5d9a9de40e48974 Mon Sep 17 00:00:00 2001 From: mammo0 Date: Fri, 24 Feb 2023 16:21:39 +0100 Subject: [PATCH] feat: by default use the latest poetry version (#62) * by default install the latest poetry version * 'poetry-version' input is not required anymore * added test install case for the 'latest' version * move if expression above run statement --- .github/workflows/ci.yml | 2 +- action.yml | 11 ++++++++--- 2 files changed, 9 insertions(+), 4 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 8912f6e..310330d 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -11,7 +11,7 @@ jobs: fail-fast: false matrix: python-version: ["3.7", "3.8", "3.9", "3.10", "3.11"] - poetry-version: ["1.0", "1.1.15", "1.2.2", "1.3.1"] + poetry-version: ["latest", "1.0", "1.1.15", "1.2.2", "1.3.1"] os: [ubuntu-20.04, macos-latest, windows-latest] runs-on: ${{ matrix.os }} steps: diff --git a/action.yml b/action.yml index 4d95612..cdf9323 100644 --- a/action.yml +++ b/action.yml @@ -7,11 +7,16 @@ branding: inputs: poetry-version: description: "The version of poetry to install" - required: true - default: "1.2.2" + required: false + default: "latest" runs: using: "composite" steps: - - run: | + - if: ${{ inputs.poetry-version == 'latest' }} + run: | + pip install -U poetry + shell: bash + - if: ${{ inputs.poetry-version != 'latest' }} + run: | pip install poetry==${{ inputs.poetry-version }} shell: bash