Skip to content

feat: add bzl7 example #50

feat: add bzl7 example

feat: add bzl7 example #50

name: "Build projects"
on:
pull_request:
push:
branches:
- "master"
jobs:
full-build:
name: build ${{ matrix.project }} on ${{ matrix.os }}
strategy:
matrix:
os: [ ubuntu-latest, ubuntu-18.04, macos-latest, macos-10.15 ]
project: [ bzl4, bzl5_bzlmod ]
runs-on: ${{ matrix.os }}
steps:
- name: Checkout code
uses:
actions/checkout@v2.4.0
# Flakes do not like shallow clones
with:
fetch-depth: 0
# Mandatory to install 'coreutils' on MacOS
- name: Install coreutils on macOS
if: startsWith(matrix.os, 'macos')
run: |
brew install coreutils
- name: Install nix on macOS
if: startsWith(matrix.os, 'macos')
uses: cachix/install-nix-action@v15
with:
nix_path: nixpkgs=channel:nixos-unstable
- name: Build all
run: ./nix-shell.sh -- --run 'cd projects/${{ matrix.project }}; bazel build //...'