ci: use runner Python for repository card checks

Signed-off-by: Feng Ruohang <rh@vonng.com>
This commit is contained in:
Feng Ruohang
2026-10-24 12:42:50 +08:00
parent 945dc16060
commit 000e653038
+10 -8
View File
@@ -34,10 +34,11 @@ jobs:
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7 - uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7
with: with:
persist-credentials: false persist-credentials: false
- uses: actions/setup-python@ece7cb06caefa5fff74198d8649806c4678c61a1 # v6 - name: Use the runner's Python in an isolated environment
with: run: |
python-version: "3.13" python3 -m venv "$RUNNER_TEMP/repository-cards-venv"
- run: python -m pip install -r buildscripts/repository-cards/requirements.txt "$RUNNER_TEMP/repository-cards-venv/bin/python" -m pip install -r buildscripts/repository-cards/requirements.txt
echo "$RUNNER_TEMP/repository-cards-venv/bin" >> "$GITHUB_PATH"
- run: python -m unittest discover -s buildscripts/repository-cards -p 'test_*.py' -v - run: python -m unittest discover -s buildscripts/repository-cards -p 'test_*.py' -v
publish: publish:
@@ -54,10 +55,11 @@ jobs:
OUTPUT_BRANCH: codex/repository-cards OUTPUT_BRANCH: codex/repository-cards
steps: steps:
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7 - uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7
- uses: actions/setup-python@ece7cb06caefa5fff74198d8649806c4678c61a1 # v6 - name: Use the runner's Python in an isolated environment
with: run: |
python-version: "3.13" python3 -m venv "$RUNNER_TEMP/repository-cards-venv"
- run: python -m pip install -r buildscripts/repository-cards/requirements.txt "$RUNNER_TEMP/repository-cards-venv/bin/python" -m pip install -r buildscripts/repository-cards/requirements.txt
echo "$RUNNER_TEMP/repository-cards-venv/bin" >> "$GITHUB_PATH"
- name: Load the generated-assets branch - name: Load the generated-assets branch
shell: bash shell: bash