Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
…dule into dev
  • Loading branch information
Willy-JL committed Jun 2, 2024
2 parents a9e65c4 + b57986d commit 3f25703
Show file tree
Hide file tree
Showing 3 changed files with 365 additions and 18 deletions.
35 changes: 17 additions & 18 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,14 +3,14 @@ name: build
on:
push:
branches:
- main
- dev
tags:
- '*'
pull_request:

jobs:
build:
runs-on: ubuntu-latest
runs-on: ubuntu-22.04
steps:
- name: 'Wipe workspace'
run: find ./ -mount -maxdepth 1 -exec rm -rf {} \;
Expand All @@ -21,13 +21,21 @@ jobs:
submodules: false
ref: ${{ github.event.pull_request.head.sha }}

- name: 'Checkout submodules'
run: git submodule update --init --recursive --depth 1 --jobs "$(getconf _NPROCESSORS_ONLN)";
- name: 'Set toolchain envs'
run: |
echo "FBT_TOOLCHAIN_PATH=$(pwd)" >> $GITHUB_ENV
- name: 'Setup python'
uses: actions/setup-python@v4
- name: 'Download toolchain'
run: |
source scripts/toolchain/fbtenv.sh
- name: 'Setup cmake'
uses: jwlawson/actions-setup-cmake@v2
with:
python-version: '3.11'
cmake-version: '3.29.0'

- name: 'Checkout submodules'
run: git submodule update --init --recursive --depth 1 --jobs "$(getconf _NPROCESSORS_ONLN)";

- name: 'Get commit details'
id: names
Expand All @@ -39,25 +47,16 @@ jobs:
else
TYPE="other"
fi
source scripts/toolchain/fbtenv.sh;
python3 scripts/get_env.py \
"--event_file=${{ github.event_path }}" \
"--type=$TYPE" \
"--github_auth_token=${{ secrets.GITHUB_TOKEN }}";
echo "event_type=$TYPE" >> $GITHUB_OUTPUT
- name: 'Install arm-none-eabi-gcc'
uses: ryanwinter/arm-none-eabi-gcc@master
with:
release: '10-2021.10'

- name: 'Install protoc'
uses: arduino/setup-protoc@v2

- name: 'Install python tools'
run: python3 -m pip install protobuf grpcio-tools

- name: 'Build firmware'
run: |
source scripts/toolchain/fbtenv.sh;
pushd build;
cmake -DCMAKE_BUILD_TYPE=Release ../;
make -j"$(getconf _NPROCESSORS_ONLN)";
Expand Down
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
toolchain/

# Prerequisites
*.d

Expand Down
Loading

0 comments on commit 3f25703

Please sign in to comment.