Skip to content

Commit 28fa245

Browse files
committed
fix: python version
1 parent 8c475a2 commit 28fa245

File tree

6 files changed

+11
-38
lines changed

6 files changed

+11
-38
lines changed
Lines changed: 6 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -1,29 +1,22 @@
11
name: Install Python with uv
22
description: |
33
This GitHub Action installs Python using the uv tool.
4-
It pins the specified Python version, caches uv files, and installs dependencies.
5-
6-
inputs:
7-
python-version:
8-
description: Python version
9-
required: true
4+
It caches uv files, and installs dependencies.
105
116
runs:
127
using: composite
138

149
steps:
10+
- name: Extract Python Version
11+
run: echo "PYTHON_VERSION=$(cat .python-version)" >> $GITHUB_ENV
12+
shell: bash
13+
1514
- name: Install uv
1615
uses: astral-sh/setup-uv@v6
1716
with:
1817
enable-cache: true
19-
python-version: ${{ inputs.python-version }}
18+
python-version: ${{ env.PYTHON_VERSION }}
2019

2120
- name: Install Dependencies
2221
run: uv sync --frozen
2322
shell: bash
24-
25-
- name: Activate venv
26-
run: |
27-
uv venv
28-
source .venv/bin/activate
29-
shell: bash

.github/workflows/format.yml

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -10,18 +10,12 @@ jobs:
1010
ruff:
1111
runs-on: ubuntu-latest
1212

13-
strategy:
14-
matrix:
15-
python-version: ["3.9", "3.10", "3.11", "3.12", "3.13"]
16-
1713
steps:
1814
- name: Checkout
1915
uses: actions/checkout@v4
2016

21-
- name: Setup Python ${{ matrix.python-version }} with uv
17+
- name: Setup Python with uv
2218
uses: ./.github/actions/setup-python-with-uv
23-
with:
24-
python-version: ${{ matrix.python-version }}
2519

2620
- name: Format by Ruff
2721
run: uv run nox -s fmt

.github/workflows/gh-deploy.yml

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -23,10 +23,8 @@ jobs:
2323
name: github-actions[bot]
2424
email: 41898282+github-actions[bot]@users.noreply.github.com
2525

26-
- name: Setup Python 3.13 with uv
26+
- name: Setup Python with uv
2727
uses: ./.github/actions/setup-python-with-uv
28-
with:
29-
python-version: 3.13
3028

3129
- name: Generate cache id
3230
run: echo "cache_id=$(date --utc '+%V')" >> $GITHUB_ENV

.github/workflows/lint.yml

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -10,18 +10,12 @@ jobs:
1010
pyright-and-ruff:
1111
runs-on: ubuntu-latest
1212

13-
strategy:
14-
matrix:
15-
python-version: ["3.9", "3.10", "3.11", "3.12", "3.13"]
16-
1713
steps:
1814
- name: Checkout
1915
uses: actions/checkout@v4
2016

21-
- name: Setup Python ${{ matrix.python-version }} with uv
17+
- name: Setup Python with uv
2218
uses: ./.github/actions/setup-python-with-uv
23-
with:
24-
python-version: ${{ matrix.python-version }}
2519

2620
- name: Lint by Pyright and Ruff
2721
run: uv run nox -s lint

.github/workflows/test.yml

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -10,18 +10,12 @@ jobs:
1010
coverage:
1111
runs-on: ubuntu-latest
1212

13-
strategy:
14-
matrix:
15-
python-version: ["3.13"]
16-
1713
steps:
1814
- name: Checkout
1915
uses: actions/checkout@v4
2016

21-
- name: Setup Python ${{ matrix.python-version }} with uv
17+
- name: Setup Python with uv
2218
uses: ./.github/actions/setup-python-with-uv
23-
with:
24-
python-version: ${{ matrix.python-version }}
2519

2620
- name: Run pytest
2721
run: |

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
[![uv](https://img.shields.io/endpoint?url=https://raw.githubusercontent.com/astral-sh/uv/main/assets/badge/v0.json)](https://github.com/astral-sh/uv)
66
[![Ruff](https://img.shields.io/endpoint?url=https://raw.githubusercontent.com/astral-sh/ruff/main/assets/badge/v2.json)](https://github.com/astral-sh/ruff)
77

8-
[![Versions](https://img.shields.io/badge/python-3.9%20|%203.10%20|%203.11%20|%203.12%20|%203.13%20-green.svg)](https://github.com/a5chin/python-uv)
8+
[![Versions](https://img.shields.io/badge/python-3.10%20|%203.11%20|%203.12%20|%203.13%20-green.svg)](https://github.com/a5chin/python-uv)
99
![code coverage](https://raw.githubusercontent.com/a5chin/python-uv/coverage-badge/coverage.svg?raw=true)
1010

1111
[![Docker](https://github.com/a5chin/python-uv/actions/workflows/docker.yml/badge.svg)](https://github.com/a5chin/python-uv/actions/workflows/docker.yml)

0 commit comments

Comments
 (0)