Skip to content

Add an interface for aggregating branch frequencies #599

Add an interface for aggregating branch frequencies

Add an interface for aggregating branch frequencies #599

Workflow file for this run

# Copyright 2024 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
name: Propeller CI
on:
push:
branches: [main, copybara_staging]
pull_request:
branches: [main]
# Allows for manually triggering workflow runs.
workflow_dispatch:
# https://docs.github.com/en/actions/reference/workflow-syntax-for-github-actions#jobs
jobs:
build-and-test:
runs-on: ubuntu-22.04-16core
steps:
- name: Checkout the repo
uses: actions/checkout@v4
- name: Configure the runner
run: |
sudo apt-get update
sudo apt-get install ninja-build libelf-dev
- name: Mount the Bazel cache
uses: actions/cache@v4
with:
path: |
~/.cache/bazel
# To avoid drift, we always want to update the cache. We use a unique primary key so that
# there is never a cache hit on the primary key, but there *is* a cache hit on one of the
# restore keys; this way, we fetch relevant entries, but always write back the cache.
key: ${{ runner.os }}-bazel-${{ hashFiles('.bazelversion', '.bazelrc', 'WORKSPACE', 'WORKSPACE.bazel', 'MODULE.bazel') }}-${{ github.run_id }}
restore-keys: |
${{ runner.os }}-bazel-${{ hashFiles('.bazelversion', '.bazelrc', 'WORKSPACE', 'WORKSPACE.bazel', 'MODULE.bazel') }}-
${{ runner.os }}-bazel-
# Currently, we only have builds on Ubuntu 22.04 for x86_64.
- name: Build (Bazel)
run: bazel build //propeller/...:all
- name: Test (Bazel)
run: bazel test //propeller/...:all
- name: Configure (CMake)
run: cmake -G Ninja -B build
- name: Build (CMake)
run: ninja -C build
- name: Test (CMake)
run: ninja -C build test