attic-action/.github/workflows/test.yml

42 lines
880 B
YAML
Raw Normal View History

name: "Test"
on:
push:
branches: ["main"]
workflow_call:
workflow_dispatch:
jobs:
test-cache:
strategy:
matrix:
os: [ubuntu-latest, macos-latest]
runs-on: ${{ matrix.os }}
steps:
- name: Checkout repository
uses: actions/checkout@v4
2023-07-19 02:51:10 +00:00
- uses: pnpm/action-setup@v2
- uses: actions/setup-node@v4
2023-07-19 02:51:10 +00:00
with:
cache: pnpm
cache-dependency-path: pnpm-lock.yaml
- name: Build
run: pnpm install && pnpm build
- name: Install Nix
uses: DeterminateSystems/nix-installer-action@v5
- name: Setup Attic Cache
uses: ./
with:
endpoint: ${{ secrets.ATTIC_ENDPOINT }}
cache: ${{ secrets.ATTIC_CACHE }}
token: ${{ secrets.ATTIC_TOKEN }}
2023-07-19 02:51:10 +00:00
- name: Build Nix Package
run: nix build --impure --show-trace -L .#test