mirror of
https://github.com/astral-sh/setup-uv.git
synced 2025-05-17 06:34:45 +00:00
Detect required-version from config file (#233)
1. If defined use version input 2. If defined use uv-file input 3. If defined use pyproject-file input 4. Search for required-version in uv.toml in repo root 5. Search for required-version in pyproject.toml in repo root 6. Use latest Closes: #215
This commit is contained in:
parent
d577e74f98
commit
5ce9ee0011
18 changed files with 2436 additions and 19 deletions
33
.github/workflows/test.yml
vendored
33
.github/workflows/test.yml
vendored
|
@ -64,6 +64,39 @@ jobs:
|
|||
fi
|
||||
env:
|
||||
UV_VERSION: ${{ steps.setup-uv.outputs.uv-version }}
|
||||
test-pyproject-file-version:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
- name: Install version 0.5.14
|
||||
id: setup-uv
|
||||
uses: ./
|
||||
with:
|
||||
pyproject-file: "__tests__/fixtures/pyproject-toml-project/pyproject.toml"
|
||||
- name: Correct version gets installed
|
||||
run: |
|
||||
if [ "$UV_VERSION" != "0.5.14" ]; then
|
||||
exit 1
|
||||
fi
|
||||
env:
|
||||
UV_VERSION: ${{ steps.setup-uv.outputs.uv-version }}
|
||||
test-uv-file-version:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
- name: Install version 0.5.15
|
||||
id: setup-uv
|
||||
uses: ./
|
||||
with:
|
||||
pyproject-file: "__tests__/fixtures/uv-toml-project/pyproject.toml"
|
||||
uv-file: "__tests__/fixtures/uv-toml-project/uv.toml"
|
||||
- name: Correct version gets installed
|
||||
run: |
|
||||
if [ "$UV_VERSION" != "0.5.15" ]; then
|
||||
exit 1
|
||||
fi
|
||||
env:
|
||||
UV_VERSION: ${{ steps.setup-uv.outputs.uv-version }}
|
||||
test-checksum:
|
||||
runs-on: ${{ matrix.os }}
|
||||
strategy:
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue