-
Notifications
You must be signed in to change notification settings - Fork 2
49 lines (45 loc) · 1.43 KB
/
main.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
# Copyright lowRISC contributors (OpenTitan project).
# Licensed under the Apache License, Version 2.0, see LICENSE for details.
# SPDX-License-Identifier: Apache-2.0
name: CI
on: [push, pull_request]
jobs:
# Run lint checks on codebase.
lint:
# https://github.com/actions/runner-images/blob/main/images/linux/Ubuntu2204-Readme.md
runs-on: ubuntu-22.04
timeout-minutes: 30
steps:
- uses: actions/checkout@v2
- name: Run linter checks
run: bazel test //quality/...
# Build and test everything in codebase.
test:
runs-on: ubuntu-22.04
timeout-minutes: 80
steps:
- uses: actions/checkout@v2
- name: Build everything
run: |
bazel build //...
bazel run //release:release -- \
--norelease \
--copy "${PWD}/artifacts" \
"no_tag_not_a_release"
- name: Upload build artifacts
uses: actions/upload-artifact@v3
with:
name: artifacts
path: artifacts/*
- name: Test everything
# Skip running lint tests as those are run in a previous stage.
run: bazel test --test_tag_filters=-lint //...
# Test airgapped build.
airgapped_build_test:
runs-on: ubuntu-22.04
timeout-minutes: 80
steps:
- uses: actions/checkout@v2
- name: Build everything in an airgapped network namespace.
run: |
./util/airgapped_builds/test-airgapped-build.sh