-
Notifications
You must be signed in to change notification settings - Fork 3
68 lines (59 loc) · 2.09 KB
/
build.yaml
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
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
name: Simple Build Test
on:
push:
pull_request:
schedule:
- cron: '0 21 * * *' # Run it every day at 9pm UTC
concurrency:
group: ${{ github.workflow }}-${{ github.event_name }}-${{ github.head_ref || github.ref }}
cancel-in-progress: true
jobs:
simple-build:
runs-on: ubuntu-22.04
if: github.repository == 'spacecubics/scsat1-fsw'
container:
image: ghcr.io/zephyrproject-rtos/ci:v0.26.1
options: '--entrypoint /bin/bash'
strategy:
fail-fast: false
env:
ZEPHYR_SDK_INSTALL_DIR: /opt/toolchains/zephyr-sdk-0.16.0
ZEPHYR_TOOLCHAIN_VARIANT: zephyr
steps:
- name: Apply container owner mismatch workaround
run: |
# FIXME: The owner UID of the GITHUB_WORKSPACE directory may not
# match the container user UID because of the way GitHub
# Actions runner is implemented. Remove this workaround when
# GitHub comes up with a fundamental fix for this problem.
git config --global --add safe.directory ${GITHUB_WORKSPACE}
- name: Update PATH for west
run: |
echo "$HOME/.local/bin" >> $GITHUB_PATH
- name: Checkout
uses: actions/checkout@v3
with:
ref: ${{ github.event.pull_request.head.sha }}
fetch-depth: 0
- name: Configure Git
run: |
git config --global user.email github@spacecubics.com
git config --global user.name "Github Actions"
- name: Setup Git (pull request)
if: ${{ github.base_ref }}
env:
BASE_REF: ${{ github.base_ref }}
run: |
git rebase origin/${BASE_REF}
git checkout -b this_pr
- name: West Setup
run: |
west init -l . || true
west config --global update.narrow true
west config --global build.board_warn false
west update 2>&1 1> west.update.log || west update 2>&1 1> west.update.log
- name: Build the PR
run: |
west build -d build-boot bootloader
west build -d build-main main
west build -d build-adcs adcs