From de1e46805fbdfc7cb99c6bbd340c91bcbee07f63 Mon Sep 17 00:00:00 2001 From: Peter Johanson Date: Sat, 25 Nov 2023 00:55:11 +0000 Subject: [PATCH] feat(build): Build unified config/mod repos. * Detect in our build script if our config repo is *also* a Zephyr module and if so pass to ZMK build in ZMK_EXTRA_MODULES define. --- .github/workflows/build-user-config.yml | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/.github/workflows/build-user-config.yml b/.github/workflows/build-user-config.yml index 7373c9ff4c53..69018294bf32 100644 --- a/.github/workflows/build-user-config.yml +++ b/.github/workflows/build-user-config.yml @@ -52,6 +52,9 @@ jobs: fail-fast: false matrix: ${{ fromJson(needs.matrix.outputs.build_matrix) }} steps: + - name: Checkout + uses: actions/checkout@v3 + - name: Prepare variables shell: sh -x {0} env: @@ -59,14 +62,13 @@ jobs: shield: ${{ matrix.shield }} artifact_name: ${{ matrix.artifact-name }} run: | + ls zephyr/ + if [ -e zephyr/module.yml ]; then export zmk_extra_modules_arg=" -DZMK_EXTRA_MODULES='$(pwd)'"; fi echo "zephyr_version=${ZEPHYR_VERSION}" >> $GITHUB_ENV - echo "extra_cmake_args=${shield:+-DSHIELD=\"$shield\"}" >> $GITHUB_ENV + echo "extra_cmake_args=${shield:+-DSHIELD=\"$shield\"}${zmk_extra_modules_arg}" >> $GITHUB_ENV echo "display_name=${shield:+$shield - }${board}" >> $GITHUB_ENV echo "artifact_name=${artifact_name:-${shield:+$shield-}${board}-zmk}" >> $GITHUB_ENV - - name: Checkout - uses: actions/checkout@v3 - - name: Cache west modules uses: actions/cache@v3.0.11 continue-on-error: true