Skip to content

Commit

Permalink
Support latest main branch commit for poetry-version (#75)
Browse files Browse the repository at this point in the history
Related to #74

Add support for installing the latest `main` branch commit of Poetry.

* **action.yml**
  - Add a new condition to check if `poetry-version` is "main".
  - Add a new step to install the latest `main` branch commit of Poetry if `poetry-version` is "main".
  - Update the condition for installing specific versions of Poetry to exclude "main".

* **.github/workflows/ci.yml**
  - Add "main" to the `poetry-version` matrix.

---

For more details, open the [Copilot Workspace session](https://copilot-workspace.githubnext.com/abatilo/actions-poetry/issues/74?shareId=XXXX-XXXX-XXXX-XXXX).
  • Loading branch information
abatilo authored Aug 8, 2024
1 parent d79ef3c commit 3fde3e5
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 2 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ jobs:
fail-fast: false
matrix:
python-version: ["3.8", "3.9", "3.10", "3.11"]
poetry-version: ["latest", "1.2.2", "1.3.2", "1.4.2", "1.5.1", "1.6.1"]
poetry-version: ["latest", "main", "1.2.2", "1.3.2", "1.4.2", "1.5.1", "1.6.1"]
os: [ubuntu-22.04, macos-latest, windows-latest]
runs-on: ${{ matrix.os }}
steps:
Expand Down
6 changes: 5 additions & 1 deletion action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,11 @@ runs:
run: |
pipx install poetry
shell: bash
- if: ${{ inputs.poetry-version != 'latest' }}
- if: ${{ inputs.poetry-version == 'main' }}
run: |
pipx install git+https://github.com/python-poetry/poetry.git@main
shell: bash
- if: ${{ inputs.poetry-version != 'latest' && inputs.poetry-version != 'main' }}
run: |
pipx install poetry==${{ inputs.poetry-version }}
shell: bash
Expand Down

0 comments on commit 3fde3e5

Please sign in to comment.