Skip to content

Commit 0bf32dc

Browse files
committed
add github actions
1 parent 524dad1 commit 0bf32dc

File tree

1 file changed

+33
-0
lines changed

1 file changed

+33
-0
lines changed

.github/workflows/ci.yml

Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,33 @@
1+
name: CI
2+
3+
on: [push, pull_request]
4+
5+
jobs:
6+
test:
7+
# virtual environments: https://github.com/actions/virtual-environments
8+
runs-on: ubuntu-20.04
9+
10+
steps:
11+
# Caches and restores the bazelisk download directory, the bazel build directory.
12+
- name: Cache bazel
13+
uses: actions/cache@v2
14+
env:
15+
cache-name: bazel-cache
16+
with:
17+
path: |
18+
~/.cache/bazelisk
19+
~/.cache/bazel
20+
key: ${{ runner.os }}-${{ env.cache-name }}-${{ github.ref }}
21+
restore-keys: |
22+
${{ runner.os }}-${{ env.cache-name }}-development
23+
24+
# Checks-out your repository under $GITHUB_WORKSPACE, which is the CWD for
25+
# the rest of the steps
26+
- uses: actions/checkout@v2
27+
28+
# build
29+
- name: Build the code
30+
run: bazel build //...
31+
- name: Run the test
32+
run: bazel test //...
33+

0 commit comments

Comments
 (0)