Skip to content

Commit

Permalink
Use a matrix to build all platforms
Browse files Browse the repository at this point in the history
  • Loading branch information
krichardsson committed Oct 3, 2022
1 parent b370e20 commit 2463025
Showing 1 changed file with 16 additions and 65 deletions.
81 changes: 16 additions & 65 deletions .github/workflows/CI.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,68 +14,19 @@ permissions:
contents: read

jobs:
cf2:
runs-on: ubuntu-latest

steps:
- name: Checkout Repo
uses: actions/checkout@v2
with:
submodules: true

- name: build
run: docker run --rm -v ${PWD}:/module bitcraze/builder bash -c "make defconfig && ./tools/build/build UNIT_TEST_STYLE=min"

- name: Upload Build Artifact
uses: actions/[email protected]
with:
name: cf2-${{ github.sha }}
path: |
cf2.bin
cf2.elf
bolt:
basic_build:
needs: read_targets_from_file
runs-on: ubuntu-latest

steps:
- name: Checkout Repo
uses: actions/checkout@v2
with:
submodules: true

- name: build
run: docker run --rm -v ${PWD}:/module bitcraze/builder bash -c "make bolt_defconfig && ./tools/build/build UNIT_TEST_STYLE=min"

- name: Upload Build Artifact
uses: actions/[email protected]
with:
name: bolt-${{ github.sha }}
path: |
bolt.bin
bolt.elf
tag:
runs-on: ubuntu-latest

steps:
- name: Checkout Repo
uses: actions/checkout@v2
with:
submodules: true

- name: build
run: docker run --rm -v ${PWD}:/module bitcraze/builder bash -c "make tag_defconfig && ./tools/build/build UNIT_TEST_STYLE=min"

- name: Upload Build Artifact
uses: actions/[email protected]
with:
name: tag-${{ github.sha }}
path: |
tag.bin
tag.elf
cfbl:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
platform:
- cf2
- bolt
- tag

steps:
- name: Checkout Repo
Expand All @@ -84,19 +35,19 @@ jobs:
submodules: true

- name: build
run: docker run --rm -v ${PWD}:/module bitcraze/builder bash -c "make cfbl_defconfig && ./tools/build/build UNIT_TEST_STYLE=min"
run: docker run --rm -v ${PWD}:/module bitcraze/builder bash -c "make ${{ matrix.platform }}_defconfig && ./tools/build/build UNIT_TEST_STYLE=min"

- name: Upload Build Artifact
uses: actions/[email protected]
with:
name: cfbl-${{ github.sha }}
name: ${{ matrix.platform }}-${{ github.sha }}
path: |
cfbl.bin
cfbl.elf
${{ matrix.platform }}.bin
${{ matrix.platform }}.elf
features:
runs-on: ubuntu-latest
needs: cf2
needs: basic_build

strategy:
fail-fast: false
Expand Down Expand Up @@ -132,7 +83,7 @@ jobs:

apps:
runs-on: ubuntu-latest
needs: cf2
needs: basic_build

strategy:
fail-fast: false
Expand Down Expand Up @@ -160,7 +111,7 @@ jobs:

kbuild-targets:
runs-on: ubuntu-latest
needs: cf2
needs: basic_build

strategy:
fail-fast: false
Expand Down

0 comments on commit 2463025

Please sign in to comment.