2023-01-16 15:29:02 +00:00
|
|
|
name: Build and Test with Bazel
|
|
|
|
|
2023-01-23 15:32:39 +00:00
|
|
|
on:
|
2023-01-19 10:38:48 +00:00
|
|
|
push:
|
|
|
|
branches:
|
|
|
|
- 'main'
|
|
|
|
pull_request:
|
2023-01-16 15:29:02 +00:00
|
|
|
|
|
|
|
jobs:
|
|
|
|
build:
|
|
|
|
timeout-minutes: 120
|
|
|
|
strategy:
|
|
|
|
matrix:
|
|
|
|
os: [ubuntu-latest, macos-latest, windows-latest]
|
|
|
|
|
|
|
|
runs-on: ${{matrix.os}}
|
|
|
|
|
|
|
|
steps:
|
|
|
|
- uses: actions/checkout@v3
|
2023-01-23 15:32:39 +00:00
|
|
|
with:
|
|
|
|
fetch-depth: '0'
|
2023-01-16 15:29:02 +00:00
|
|
|
- name: Download dependencies
|
|
|
|
run: python3 utils/git-sync-deps
|
|
|
|
- name: Mount Bazel cache
|
|
|
|
uses: actions/cache@v3
|
|
|
|
with:
|
|
|
|
path: ~/.bazel/cache
|
|
|
|
key: bazel-cache-${{ runner.os }}
|
|
|
|
- name: Build All
|
|
|
|
run: bazel --output_user_root=~/.bazel/cache build //...
|
|
|
|
- name: Test All
|
|
|
|
run: bazel --output_user_root=~/.bazel/cache test //...
|