mirror of
https://codeberg.org/unspeaker/tek.git
synced 2025-12-07 20:26:42 +01:00
ci: try caching
This commit is contained in:
parent
8e5c4d0aba
commit
92271f727d
2 changed files with 29 additions and 38 deletions
|
|
@ -1,12 +1,25 @@
|
|||
on: [push]
|
||||
jobs:
|
||||
build:
|
||||
container:
|
||||
image: alpine:edge
|
||||
container: { image: "alpine:edge" }
|
||||
steps:
|
||||
- run: apk update
|
||||
- run: apk add tree rustup git just cloc build-base clang20-dev pipewire-jack-dev lilv-dev serd-dev
|
||||
- run: git clone --recursive $GITHUB_SERVER_URL/$GITHUB_REPOSITORY .
|
||||
|
||||
- name: install deps
|
||||
run: apk add --no-cache nodejs tree rustup git just cloc build-base clang20-dev pipewire-jack-dev lilv-dev serd-dev
|
||||
|
||||
- id: cache
|
||||
name: cache restore
|
||||
uses: https://data.forgejo.org/actions/cache/restore@v4
|
||||
with:
|
||||
key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.lock') }}
|
||||
path: |
|
||||
~/.cargo/bin/
|
||||
~/.cargo/registry/index/
|
||||
~/.cargo/registry/cache/
|
||||
~/.cargo/git/db/
|
||||
target/
|
||||
|
||||
- run: git clone --depth 1 --recursive $GITHUB_SERVER_URL/$GITHUB_REPOSITORY .
|
||||
- run: whoami && pwd && tree
|
||||
- run: cloc src/ && cloc .
|
||||
- run: rustup-init -y
|
||||
|
|
@ -15,3 +28,14 @@ jobs:
|
|||
- run: source "$HOME/.cargo/env" && RUSTFLAGS="-Ctarget-feature=-crt-static" just test
|
||||
- run: source "$HOME/.cargo/env" && RUSTFLAGS="-Ctarget-feature=-crt-static" just build-release
|
||||
- run: tree
|
||||
|
||||
- name: cache save
|
||||
uses: https://data.forgejo.org/actions/cache/save@v4
|
||||
with:
|
||||
key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.lock') }}
|
||||
path: |
|
||||
~/.cargo/bin/
|
||||
~/.cargo/registry/index/
|
||||
~/.cargo/registry/cache/
|
||||
~/.cargo/git/db/
|
||||
target/
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue