From c72612d8266dbeebdd747c469ac9301b9068f82f Mon Sep 17 00:00:00 2001 From: Jason Murray <15822260+scruplelesswizard@users.noreply.github.com> Date: Tue, 24 Sep 2024 00:41:40 -0700 Subject: [PATCH] sed doesn't like newlines (#4847) * sed doesn't like newlines * fold remove-debug-flags block * PATH is a system env var * Runners don't like rm -f ${workspace path} --- .github/actions/build-variant/action.yml | 11 +++-------- .github/workflows/build_esp32.yml | 2 +- .github/workflows/build_esp32_c3.yml | 2 +- .github/workflows/build_esp32_s3.yml | 2 +- 4 files changed, 6 insertions(+), 11 deletions(-) diff --git a/.github/actions/build-variant/action.yml b/.github/actions/build-variant/action.yml index b698f9e57..f9410eb03 100644 --- a/.github/actions/build-variant/action.yml +++ b/.github/actions/build-variant/action.yml @@ -12,7 +12,7 @@ inputs: description: Path to the build script required: true remove-debug-flags: - description: A newline separated list of files to remove debug flags from + description: A space separated list of files to remove debug flags from required: false default: "" ota-firmware-source: @@ -59,8 +59,8 @@ runs: shell: bash if: inputs.remove-debug-flags != '' run: | - for PATH in ${{ inputs.remove-debug-flags }}; do - sed -i '/DDEBUG_HEAP/d' ${PATH} + for INI_FILE in ${{ inputs.remove-debug-flags }}; do + sed -i '/DDEBUG_HEAP/d' ${INI_FILE} done - name: Build ${{ inputs.board }} @@ -88,8 +88,3 @@ runs: overwrite: true path: | ${{ inputs.artifact-paths }} - - - name: Clean up resources - shell: bash - run: | - rm -rf . diff --git a/.github/workflows/build_esp32.yml b/.github/workflows/build_esp32.yml index 350454e18..5f97a349f 100644 --- a/.github/workflows/build_esp32.yml +++ b/.github/workflows/build_esp32.yml @@ -19,7 +19,7 @@ jobs: with: github_token: ${{ secrets.GITHUB_TOKEN }} board: ${{ inputs.board }} - remove-debug-flags: | + remove-debug-flags: > ./arch/esp32/esp32.ini ./arch/esp32/esp32s2.ini ./arch/esp32/esp32s3.ini diff --git a/.github/workflows/build_esp32_c3.yml b/.github/workflows/build_esp32_c3.yml index abfeb1f5a..8f3ded187 100644 --- a/.github/workflows/build_esp32_c3.yml +++ b/.github/workflows/build_esp32_c3.yml @@ -21,7 +21,7 @@ jobs: with: github_token: ${{ secrets.GITHUB_TOKEN }} board: ${{ inputs.board }} - remove-debug-flags: | + remove-debug-flags: > ./arch/esp32/esp32.ini ./arch/esp32/esp32s2.ini ./arch/esp32/esp32s3.ini diff --git a/.github/workflows/build_esp32_s3.yml b/.github/workflows/build_esp32_s3.yml index 174c0f941..40d05573c 100644 --- a/.github/workflows/build_esp32_s3.yml +++ b/.github/workflows/build_esp32_s3.yml @@ -19,7 +19,7 @@ jobs: with: github_token: ${{ secrets.GITHUB_TOKEN }} board: ${{ inputs.board }} - remove-debug-flags: | + remove-debug-flags: > ./arch/esp32/esp32.ini ./arch/esp32/esp32s2.ini ./arch/esp32/esp32s3.ini