Skip to content

Commit

Permalink
Merge pull request #40 from DeterminateSystems/cache-dev-shells
Browse files Browse the repository at this point in the history
Cache dev shell in FlakeHub Cache
  • Loading branch information
edolstra committed Mar 29, 2024
2 parents e734a0a + 9252645 commit a08d2ea
Showing 1 changed file with 32 additions and 0 deletions.
32 changes: 32 additions & 0 deletions .github/workflows/flakehub-cache.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
name: Push dev shell to FlakeHub Cache

on:
push:
branches: [main]

jobs:
push-dev-shell-to-flakehub-cache:
env:
ACTIONS_STEP_DEBUG: true
runs-on: ${{ matrix.systems.runner }}
permissions:
id-token: "write"
contents: "read"
strategy:
matrix:
systems:
- nix-system: "aarch64-darwin"
runner: "macos-latest-xlarge"
- nix-system: "x86_64-darwin"
runner: "macos-12"
- nix-system: "x86_64-linux"
runner: "ubuntu-22.04"
steps:
- uses: actions/checkout@v3
- uses: DeterminateSystems/nix-installer-action@main
- uses: DeterminateSystems/magic-nix-cache-action@main
with:
use-flakehub: true
- name: Build dev shell for ${{ matrix.systems.nix-system }} on ${{ matrix.systems.runner }}
run: |
nix build .#devShells.${{ matrix.systems.nix-system }}.default

0 comments on commit a08d2ea

Please sign in to comment.