test for ci cache
Some checks failed
/ test-build (push) Failing after 4s

This commit is contained in:
Daniel Fichtinger 2025-07-15 23:39:00 -04:00
parent 8ad8bad438
commit 1ee879082f
2 changed files with 40 additions and 0 deletions

View file

@ -0,0 +1,26 @@
on: [push]
jobs:
test-build:
runs-on: based-alpine
steps:
- run: |
apk add --no-cache tar zstd
- name: checkout source
uses: actions/checkout@v4
- name: Get uv cache dir
id: uv-cache
shell: bash
run: |
echo "dir=$(uv cache dir)" >> $GITHUB_OUTPUT
- name: Restore uv cache
uses: actions/cache@v4
with:
path: ${{ steps.uv-cache.outputs.dir }}
key: ${{ runner.os }}-uv-${{ hashFiles('**/*requirements*.txt', '**/*requirements*.in', '**/*constraints*.txt', '**/*constraints*.in', '**/pyproject.toml', '**/uv.lock') }}
restore-keys: |
${{ runner.os }}-uv-
- name: sync and build
run: |
uv sync
uv build
uv run zona --help

14
.forgejo/workflows/uv.yml Normal file
View file

@ -0,0 +1,14 @@
on: [push]
jobs:
test-build:
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v4
- name: Install uv
uses: github.com/astral-sh/setup-uv@v6
with:
enable-cache: true
- run: uv sync && uv build
- name: test cache restored
if: steps.setup-uv.outputs.cache-hit == 'true'
run: echo "Cache was restored!"