From 3b1d04372b0a013ec2738019166c1c2e85bf0ba7 Mon Sep 17 00:00:00 2001 From: Joel Spadin Date: Fri, 13 Oct 2023 14:58:27 -0500 Subject: [PATCH] feat: Print Kconfig and DTS for failed builds Added the combined devicetree file to the user config build action. Set it and the Kconfig output to run even on a failed build. --- .github/workflows/build-user-config.yml | 22 +++++++++++++++++++++- 1 file changed, 21 insertions(+), 1 deletion(-) diff --git a/.github/workflows/build-user-config.yml b/.github/workflows/build-user-config.yml index 5891ddc1e26..c1a97b4d6e0 100644 --- a/.github/workflows/build-user-config.yml +++ b/.github/workflows/build-user-config.yml @@ -97,7 +97,27 @@ jobs: run: west build -s zmk/app -b "${{ matrix.board }}" -- -DZMK_CONFIG="${GITHUB_WORKSPACE}/${{ inputs.config_path }}" ${{ env.extra_cmake_args }} ${{ matrix.cmake-args }} - name: ${{ env.display_name }} Kconfig file - run: grep -v -e "^#" -e "^$" build/zephyr/.config | sort + run: | + if [ -f build/zephyr/.config ] + then + grep -v -e "^#" -e "^$" build/zephyr/.config | sort + else + echo "No Kconfig output" + fi + if: ${{ !cancelled() }} + + - name: ${{ env.display_name }} Devicetree file + run: | + if [ -f build/zephyr/zephyr.dts ] + then + cat build/zephyr/zephyr.dts + elif [ -f build/zephyr/zephyr.dts.pre ] + then + cat -s build/zephyr/zephyr.dts.pre + else + echo "No Devicetree output" + fi + if: ${{ !cancelled() }} - name: Rename artifacts shell: sh -x {0}