Skip to content

Commit

Permalink
Add macos testing
Browse files Browse the repository at this point in the history
  • Loading branch information
Zaczero committed May 30, 2024
1 parent 59a1361 commit 7b37d40
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 4 deletions.
9 changes: 6 additions & 3 deletions .github/workflows/workflow.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -11,20 +11,23 @@ on:
jobs:
test:
name: Run tests
runs-on: ubuntu-latest
strategy:
matrix:
os: [ubuntu-24.04, macos-14]

runs-on: ${{ matrix.os }}
steps:
- name: Checkout repository
uses: actions/checkout@v4

- name: Install Nix
uses: cachix/install-nix-action@v26
uses: cachix/install-nix-action@v27
with:
nix_path: nixpkgs=channel:nixpkgs-23.11-darwin

- name: Extract nixpkgs hash
run: |
nixpkgs_hash=$(grep -o -P '(?<=archive/)[0-9a-f]{40}(?=\.tar\.gz)' shell.nix)
nixpkgs_hash=$(egrep -o 'archive/[0-9a-f]{40}\.tar\.gz' shell.nix | cut -d'/' -f2 | cut -d'.' -f1)
echo "NIXPKGS_HASH=$nixpkgs_hash" >> $GITHUB_ENV
- name: Cache Nix store
Expand Down
2 changes: 1 addition & 1 deletion shell.nix
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

let
# Update packages with `nixpkgs-update` command
pkgs = import (fetchTarball "https://github.com/NixOS/nixpkgs/archive/860e65d27036476edfb85dd847d982277880b143.tar.gz") { };
pkgs = import (fetchTarball "https://github.com/NixOS/nixpkgs/archive/ac82a513e55582291805d6f09d35b6d8b60637a1.tar.gz") { };

pythonLibs = with pkgs; [
stdenv.cc.cc.lib
Expand Down

0 comments on commit 7b37d40

Please sign in to comment.