From 35e47a24a139c271401dc7d6041d0a800667baa9 Mon Sep 17 00:00:00 2001 From: Will Tatam Date: Mon, 4 Mar 2024 22:55:04 +0000 Subject: [PATCH 01/25] matrix compile --- .github/workflows/pio.yml | 32 ++++++++++++++++++++++++++++++-- 1 file changed, 30 insertions(+), 2 deletions(-) diff --git a/.github/workflows/pio.yml b/.github/workflows/pio.yml index ce34e695..1ca55987 100644 --- a/.github/workflows/pio.yml +++ b/.github/workflows/pio.yml @@ -3,9 +3,37 @@ name: PlatformIO CI on: [push] jobs: - build: + get_default_envs: + name: Gather Environments runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v3 + - name: Cache pip + uses: actions/cache@v3 + with: + path: ~/.cache/pip + key: ${{ runner.os }}-pip-${{ hashFiles('**/requirements.txt') }} + restore-keys: | + ${{ runner.os }}-pip- + - uses: actions/setup-python@v4 + with: + python-version: '3.9' + - name: Install PlatformIO + run: pip install -r requirements.txt + - name: Get default environments + id: envs + run: | + echo "environments=$(pio project config --json-output | jq -cr '.[0][1][0][1]')" >> $GITHUB_OUTPUT + outputs: + environments: ${{ steps.envs.outputs.environments }} + build: + runs-on: ubuntu-latest + needs: get_default_envs + strategy: + fail-fast: false + matrix: + environment: ${{ fromJSON(needs.get_default_envs.outputs.environments) }} steps: - uses: actions/checkout@v3 with: @@ -29,7 +57,7 @@ jobs: echo "git_hash=${git_hash}" >> $GITHUB_ENV echo "git_branch=${git_branch}" >> $GITHUB_ENV - name: Build PlatformIO Project - run: pio run + run: pio run -e ${{ matrix.environment }} - name: 'Upload Artifact' uses: actions/upload-artifact@v3 with: From a7202512cce2c58ec51571ddf0d73adce996ade6 Mon Sep 17 00:00:00 2001 From: Will Tatam Date: Mon, 4 Mar 2024 22:58:16 +0000 Subject: [PATCH 02/25] matrix compile --- .github/workflows/pio.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/pio.yml b/.github/workflows/pio.yml index 1ca55987..367b4809 100644 --- a/.github/workflows/pio.yml +++ b/.github/workflows/pio.yml @@ -18,8 +18,8 @@ jobs: - uses: actions/setup-python@v4 with: python-version: '3.9' - - name: Install PlatformIO - run: pip install -r requirements.txt + - name: Install PlatformIO Core + run: pip install --upgrade platformio - name: Get default environments id: envs run: | From dda8d1825467a2498944787508198ad95b687d1a Mon Sep 17 00:00:00 2001 From: Will Tatam Date: Mon, 4 Mar 2024 23:12:42 +0000 Subject: [PATCH 03/25] matrix compile --- .github/workflows/pio.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/pio.yml b/.github/workflows/pio.yml index 367b4809..57eb27c9 100644 --- a/.github/workflows/pio.yml +++ b/.github/workflows/pio.yml @@ -23,7 +23,7 @@ jobs: - name: Get default environments id: envs run: | - echo "environments=$(pio project config --json-output | jq -cr '.[0][1][0][1]')" >> $GITHUB_OUTPUT + echo "environments=$(pio project config --json-output | jq -cr '.[][0]' | grep 'env:'| awk -F: '{ print $2})" >> $GITHUB_OUTPUT outputs: environments: ${{ steps.envs.outputs.environments }} From 57f02a77c14354bbe39abfe62d9fa3d11edfa374 Mon Sep 17 00:00:00 2001 From: Will Tatam Date: Mon, 4 Mar 2024 23:13:31 +0000 Subject: [PATCH 04/25] matrix compile --- .github/workflows/pio.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/pio.yml b/.github/workflows/pio.yml index 57eb27c9..2ba66c59 100644 --- a/.github/workflows/pio.yml +++ b/.github/workflows/pio.yml @@ -23,7 +23,7 @@ jobs: - name: Get default environments id: envs run: | - echo "environments=$(pio project config --json-output | jq -cr '.[][0]' | grep 'env:'| awk -F: '{ print $2})" >> $GITHUB_OUTPUT + echo "environments=$(pio project config --json-output | jq -cr '.[][0]' | grep 'env:'| awk -F: '{ print $2}')" >> $GITHUB_OUTPUT outputs: environments: ${{ steps.envs.outputs.environments }} From 942c48f908dd7c7bbd5209aab82fcc19afe0c5cd Mon Sep 17 00:00:00 2001 From: Will Tatam Date: Mon, 4 Mar 2024 23:17:36 +0000 Subject: [PATCH 05/25] matrix compile --- .github/workflows/pio.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/pio.yml b/.github/workflows/pio.yml index 2ba66c59..9148338f 100644 --- a/.github/workflows/pio.yml +++ b/.github/workflows/pio.yml @@ -23,7 +23,7 @@ jobs: - name: Get default environments id: envs run: | - echo "environments=$(pio project config --json-output | jq -cr '.[][0]' | grep 'env:'| awk -F: '{ print $2}')" >> $GITHUB_OUTPUT + echo "environments=$(pio project config --json-output | jq -cr '.[][0]' | grep 'env:'| awk -F: '{ print $2" "}' | tr -d '\n')" >> $GITHUB_OUTPUT outputs: environments: ${{ steps.envs.outputs.environments }} From 0fb191f392666ab18f56be1814321b45723bcf9a Mon Sep 17 00:00:00 2001 From: Will Tatam Date: Mon, 4 Mar 2024 23:22:59 +0000 Subject: [PATCH 06/25] matrix compile --- .github/workflows/pio.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/pio.yml b/.github/workflows/pio.yml index 9148338f..a0289862 100644 --- a/.github/workflows/pio.yml +++ b/.github/workflows/pio.yml @@ -24,6 +24,7 @@ jobs: id: envs run: | echo "environments=$(pio project config --json-output | jq -cr '.[][0]' | grep 'env:'| awk -F: '{ print $2" "}' | tr -d '\n')" >> $GITHUB_OUTPUT + cat $GITHUB_OUTPUT outputs: environments: ${{ steps.envs.outputs.environments }} From 2da726a73b50705f59186388641fb8bb6a523385 Mon Sep 17 00:00:00 2001 From: Will Tatam Date: Mon, 4 Mar 2024 23:24:42 +0000 Subject: [PATCH 07/25] matrix compile --- .github/workflows/pio.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/pio.yml b/.github/workflows/pio.yml index a0289862..e4c2d041 100644 --- a/.github/workflows/pio.yml +++ b/.github/workflows/pio.yml @@ -23,7 +23,7 @@ jobs: - name: Get default environments id: envs run: | - echo "environments=$(pio project config --json-output | jq -cr '.[][0]' | grep 'env:'| awk -F: '{ print $2" "}' | tr -d '\n')" >> $GITHUB_OUTPUT + echo "environments=\"$(pio project config --json-output | jq -cr '.[][0]' | grep 'env:'| awk -F: '{ print $2" "}' | tr -d '\n')\"" >> $GITHUB_OUTPUT cat $GITHUB_OUTPUT outputs: environments: ${{ steps.envs.outputs.environments }} @@ -34,7 +34,7 @@ jobs: strategy: fail-fast: false matrix: - environment: ${{ fromJSON(needs.get_default_envs.outputs.environments) }} + environment: ${{ needs.get_default_envs.outputs.environments }} steps: - uses: actions/checkout@v3 with: From 066b7ec39c7d2bd288eab205b1003d82d93e4c51 Mon Sep 17 00:00:00 2001 From: Will Tatam Date: Mon, 4 Mar 2024 23:50:09 +0000 Subject: [PATCH 08/25] matrix compile --- .github/workflows/pio.yml | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/.github/workflows/pio.yml b/.github/workflows/pio.yml index e4c2d041..e996e05b 100644 --- a/.github/workflows/pio.yml +++ b/.github/workflows/pio.yml @@ -23,7 +23,8 @@ jobs: - name: Get default environments id: envs run: | - echo "environments=\"$(pio project config --json-output | jq -cr '.[][0]' | grep 'env:'| awk -F: '{ print $2" "}' | tr -d '\n')\"" >> $GITHUB_OUTPUT + echo -n "environments=" >> $GITHUB_OUTPUT + jq -c -n '$ARGS.positional' --args $(pio project config --json-output | jq -cr '.[][0]' | grep 'env:'| awk -F: '{ print $2" "}' | tr -d '\n') >> $GITHUB_OUTPUT cat $GITHUB_OUTPUT outputs: environments: ${{ steps.envs.outputs.environments }} @@ -34,7 +35,7 @@ jobs: strategy: fail-fast: false matrix: - environment: ${{ needs.get_default_envs.outputs.environments }} + environment: ${{ fromJSON(needs.get_default_envs.outputs.environments) }} steps: - uses: actions/checkout@v3 with: From 0538044adbb8fabbf174b883c83941df0c2382a1 Mon Sep 17 00:00:00 2001 From: Will Tatam Date: Mon, 4 Mar 2024 23:51:37 +0000 Subject: [PATCH 09/25] matrix compile --- .github/workflows/pio.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/pio.yml b/.github/workflows/pio.yml index e996e05b..1a4411ed 100644 --- a/.github/workflows/pio.yml +++ b/.github/workflows/pio.yml @@ -23,8 +23,8 @@ jobs: - name: Get default environments id: envs run: | - echo -n "environments=" >> $GITHUB_OUTPUT - jq -c -n '$ARGS.positional' --args $(pio project config --json-output | jq -cr '.[][0]' | grep 'env:'| awk -F: '{ print $2" "}' | tr -d '\n') >> $GITHUB_OUTPUT + echo -n "environments=" >> $GITHUB_OUTPUT + jq -c -n '$ARGS.positional' --args $(pio project config --json-output | jq -cr '.[][0]' | grep 'env:'| awk -F: '{ print $2" "}' | tr -d '\n') >> $GITHUB_OUTPUT cat $GITHUB_OUTPUT outputs: environments: ${{ steps.envs.outputs.environments }} From af04f3c47a8ed4408027443dd9d2bc95a863ff9a Mon Sep 17 00:00:00 2001 From: Will Tatam Date: Tue, 5 Mar 2024 00:02:48 +0000 Subject: [PATCH 10/25] matrix compile --- .github/workflows/pio.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/pio.yml b/.github/workflows/pio.yml index 1a4411ed..915658a4 100644 --- a/.github/workflows/pio.yml +++ b/.github/workflows/pio.yml @@ -63,7 +63,7 @@ jobs: - name: 'Upload Artifact' uses: actions/upload-artifact@v3 with: - name: StarMod-esp32-${{env.git_branch}}-${{env.git_hash}}.bin - path: .pio/build/esp32dev/firmware.bin + name: StarMod-${{ matrix.environment }}-${{env.git_branch}}-${{env.git_hash}}.bin + path: .pio/build/${{ matrix.environment }/firmware.bin retention-days: 30 From 7a16a4c75c4e5f254570a4b897f8fd9ca47022b8 Mon Sep 17 00:00:00 2001 From: Will Tatam Date: Tue, 5 Mar 2024 00:03:43 +0000 Subject: [PATCH 11/25] matrix compile --- .github/workflows/pio.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/pio.yml b/.github/workflows/pio.yml index 915658a4..bdcf0b95 100644 --- a/.github/workflows/pio.yml +++ b/.github/workflows/pio.yml @@ -63,7 +63,7 @@ jobs: - name: 'Upload Artifact' uses: actions/upload-artifact@v3 with: - name: StarMod-${{ matrix.environment }}-${{env.git_branch}}-${{env.git_hash}}.bin - path: .pio/build/${{ matrix.environment }/firmware.bin - retention-days: 30 + name: StarMod-${{ matrix.environment }}-${{env.git_branch}}-${{env.git_hash}}.bin + path: .pio/build/${{ matrix.environment }/firmware.bin + retention-days: 30 From 122a2b8f59636f444ae3d111ba4eb00a3e34c212 Mon Sep 17 00:00:00 2001 From: Will Tatam Date: Tue, 5 Mar 2024 00:04:46 +0000 Subject: [PATCH 12/25] matrix compile --- .github/workflows/pio.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/pio.yml b/.github/workflows/pio.yml index bdcf0b95..48fc07f4 100644 --- a/.github/workflows/pio.yml +++ b/.github/workflows/pio.yml @@ -64,6 +64,6 @@ jobs: uses: actions/upload-artifact@v3 with: name: StarMod-${{ matrix.environment }}-${{env.git_branch}}-${{env.git_hash}}.bin - path: .pio/build/${{ matrix.environment }/firmware.bin + path: .pio/build/${{ matrix.environment }}/firmware.bin retention-days: 30 From 32d5e2806959e0a4c184381600cf12d3bb7967ce Mon Sep 17 00:00:00 2001 From: Will Tatam Date: Tue, 5 Mar 2024 00:08:27 +0000 Subject: [PATCH 13/25] matrix compile --- .github/workflows/pio.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/pio.yml b/.github/workflows/pio.yml index 48fc07f4..361ef062 100644 --- a/.github/workflows/pio.yml +++ b/.github/workflows/pio.yml @@ -45,7 +45,7 @@ jobs: path: | ~/.cache/pip ~/.platformio/.cache - key: ${{ runner.os }}-pio + key: ${{ runner.os }}-${{ matrix.environment}}-${{ hashFiles('platformio.ini') }} - uses: actions/setup-python@v4 with: python-version: '3.9' From 52c5ed256140b172b953dca55eaaa3c94bcafd3e Mon Sep 17 00:00:00 2001 From: Will Tatam Date: Thu, 18 Apr 2024 23:48:13 +0100 Subject: [PATCH 14/25] Add release --- .github/workflows/pio.yml | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/.github/workflows/pio.yml b/.github/workflows/pio.yml index ce34e695..b2c280e1 100644 --- a/.github/workflows/pio.yml +++ b/.github/workflows/pio.yml @@ -37,3 +37,21 @@ jobs: path: .pio/build/esp32dev/firmware.bin retention-days: 30 + release: + name: Create Release + runs-on: ubuntu-latest + needs: [build] + if: startsWith(github.ref, 'refs/tags/') + steps: + - uses: actions/download-artifact@v2 + with: + name: firmware-release + - name: Create draft release + uses: softprops/action-gh-release@v1 + with: + draft: True + files: | + *.bin + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + \ No newline at end of file From b902f09784297ee4219fbae7ca737c391d8f5995 Mon Sep 17 00:00:00 2001 From: Will Tatam Date: Fri, 19 Apr 2024 00:05:41 +0100 Subject: [PATCH 15/25] Use default for branch/tag name --- .github/workflows/pio.yml | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/.github/workflows/pio.yml b/.github/workflows/pio.yml index b2c280e1..1dfb5eaf 100644 --- a/.github/workflows/pio.yml +++ b/.github/workflows/pio.yml @@ -25,15 +25,13 @@ jobs: id: vars run: | git_hash=$(git rev-parse --short "$GITHUB_SHA") - git_branch=${GITHUB_REF#refs/heads/} echo "git_hash=${git_hash}" >> $GITHUB_ENV - echo "git_branch=${git_branch}" >> $GITHUB_ENV - name: Build PlatformIO Project run: pio run - name: 'Upload Artifact' uses: actions/upload-artifact@v3 with: - name: StarMod-esp32-${{env.git_branch}}-${{env.git_hash}}.bin + name: StarMod-esp32-${{env.GITHUB_REF_NAME}}-${{env.git_hash}}.bin path: .pio/build/esp32dev/firmware.bin retention-days: 30 From e03c4078253cea4478f21abc97c8e598b7a4f3f8 Mon Sep 17 00:00:00 2001 From: Will Tatam Date: Fri, 19 Apr 2024 00:16:59 +0100 Subject: [PATCH 16/25] Define PLATFORMIO_BUILD_CACHE_DIR --- .github/workflows/pio.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/pio.yml b/.github/workflows/pio.yml index 1c4c6091..a4264c23 100644 --- a/.github/workflows/pio.yml +++ b/.github/workflows/pio.yml @@ -56,6 +56,7 @@ jobs: run: | git_hash=$(git rev-parse --short "$GITHUB_SHA") echo "git_hash=${git_hash}" >> $GITHUB_ENV + echo "PLATFORMIO_BUILD_CACHE_DIR=$HOME/.platformio/.cache" >> $GITHUB_ENV - name: Build PlatformIO Project run: pio run -e ${{ matrix.environment }} - name: 'Upload Artifact' From 387f3ab9a4d486c3f939338139db21dac75e9ba0 Mon Sep 17 00:00:00 2001 From: Will Tatam Date: Fri, 19 Apr 2024 00:21:04 +0100 Subject: [PATCH 17/25] Download all --- .github/workflows/pio.yml | 2 -- 1 file changed, 2 deletions(-) diff --git a/.github/workflows/pio.yml b/.github/workflows/pio.yml index a4264c23..d15cc471 100644 --- a/.github/workflows/pio.yml +++ b/.github/workflows/pio.yml @@ -73,8 +73,6 @@ jobs: if: startsWith(github.ref, 'refs/tags/') steps: - uses: actions/download-artifact@v2 - with: - name: firmware-release - name: Create draft release uses: softprops/action-gh-release@v1 with: From 19a80d0499c5c7f1a3c8626894303f389e4392a0 Mon Sep 17 00:00:00 2001 From: Will Tatam Date: Fri, 19 Apr 2024 00:27:38 +0100 Subject: [PATCH 18/25] List artifacts --- .github/workflows/pio.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.github/workflows/pio.yml b/.github/workflows/pio.yml index d15cc471..ed504120 100644 --- a/.github/workflows/pio.yml +++ b/.github/workflows/pio.yml @@ -73,6 +73,8 @@ jobs: if: startsWith(github.ref, 'refs/tags/') steps: - uses: actions/download-artifact@v2 + - name: List Artifacts + run: ls -lh - name: Create draft release uses: softprops/action-gh-release@v1 with: From 3bc2de2269ca3c23e02001eab11d4789a30a10f7 Mon Sep 17 00:00:00 2001 From: Will Tatam Date: Fri, 19 Apr 2024 00:37:12 +0100 Subject: [PATCH 19/25] Update GITHUB_REF_NAME referencing --- .github/workflows/pio.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/pio.yml b/.github/workflows/pio.yml index ed504120..02cf1f48 100644 --- a/.github/workflows/pio.yml +++ b/.github/workflows/pio.yml @@ -62,7 +62,7 @@ jobs: - name: 'Upload Artifact' uses: actions/upload-artifact@v3 with: - name: StarMod-${{ matrix.environment }}-${{env.GITHUB_REF_NAME}}-${{env.git_hash}}.bin + name: StarMod-${{ matrix.environment }}-${GITHUB_REF_NAME}-${{env.git_hash}}.bin path: .pio/build/${{ matrix.environment }}/firmware.bin retention-days: 30 From 330d7e182348ef2ce8d365bf1d2930dbe4d4dfcb Mon Sep 17 00:00:00 2001 From: Will Tatam Date: Fri, 19 Apr 2024 00:44:07 +0100 Subject: [PATCH 20/25] Swap to git_ref --- .github/workflows/pio.yml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/workflows/pio.yml b/.github/workflows/pio.yml index 02cf1f48..af690a89 100644 --- a/.github/workflows/pio.yml +++ b/.github/workflows/pio.yml @@ -56,13 +56,14 @@ jobs: run: | git_hash=$(git rev-parse --short "$GITHUB_SHA") echo "git_hash=${git_hash}" >> $GITHUB_ENV + echo "git_ref=${GITHUB_REF_NAME}" >> $GITHUB_ENV echo "PLATFORMIO_BUILD_CACHE_DIR=$HOME/.platformio/.cache" >> $GITHUB_ENV - name: Build PlatformIO Project run: pio run -e ${{ matrix.environment }} - name: 'Upload Artifact' uses: actions/upload-artifact@v3 with: - name: StarMod-${{ matrix.environment }}-${GITHUB_REF_NAME}-${{env.git_hash}}.bin + name: StarMod-${{ matrix.environment }}-${{env.git_ref}}-${{env.git_hash}}.bin path: .pio/build/${{ matrix.environment }}/firmware.bin retention-days: 30 From 3267f068651dd733ff57fb6d0ba393b2eef74dda Mon Sep 17 00:00:00 2001 From: Will Tatam Date: Fri, 19 Apr 2024 00:48:25 +0100 Subject: [PATCH 21/25] Cache all ~/.platformio --- .github/workflows/pio.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/pio.yml b/.github/workflows/pio.yml index af690a89..8aecd6d1 100644 --- a/.github/workflows/pio.yml +++ b/.github/workflows/pio.yml @@ -44,7 +44,7 @@ jobs: with: path: | ~/.cache/pip - ~/.platformio/.cache + ~/.platformio key: ${{ runner.os }}-${{ matrix.environment}}-${{ hashFiles('platformio.ini') }} - uses: actions/setup-python@v4 with: From 36a87bfa7aa22b650dffad3ecb80e1ae4471d250 Mon Sep 17 00:00:00 2001 From: Will Tatam Date: Fri, 19 Apr 2024 00:52:36 +0100 Subject: [PATCH 22/25] simple cache key and find --- .github/workflows/pio.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/pio.yml b/.github/workflows/pio.yml index 8aecd6d1..8b661cf2 100644 --- a/.github/workflows/pio.yml +++ b/.github/workflows/pio.yml @@ -75,7 +75,7 @@ jobs: steps: - uses: actions/download-artifact@v2 - name: List Artifacts - run: ls -lh + run: find ./ - name: Create draft release uses: softprops/action-gh-release@v1 with: From 2bfd9f165cb29a9da132d9e8db287b274097539c Mon Sep 17 00:00:00 2001 From: Will Tatam Date: Fri, 19 Apr 2024 01:02:24 +0100 Subject: [PATCH 23/25] Rename bin --- .github/workflows/pio.yml | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/.github/workflows/pio.yml b/.github/workflows/pio.yml index 8b661cf2..fd7ddcba 100644 --- a/.github/workflows/pio.yml +++ b/.github/workflows/pio.yml @@ -45,7 +45,7 @@ jobs: path: | ~/.cache/pip ~/.platformio - key: ${{ runner.os }}-${{ matrix.environment}}-${{ hashFiles('platformio.ini') }} + key: ${{ runner.os }}-${{ matrix.environment}} - uses: actions/setup-python@v4 with: python-version: '3.9' @@ -60,11 +60,12 @@ jobs: echo "PLATFORMIO_BUILD_CACHE_DIR=$HOME/.platformio/.cache" >> $GITHUB_ENV - name: Build PlatformIO Project run: pio run -e ${{ matrix.environment }} + - name: Rename Bin + run: mv .pio/build/${{ matrix.environment }}/firmware.bin StarMod-${{ matrix.environment }}-${{env.git_ref}}-${{env.git_hash}}.bin - name: 'Upload Artifact' uses: actions/upload-artifact@v3 with: - name: StarMod-${{ matrix.environment }}-${{env.git_ref}}-${{env.git_hash}}.bin - path: .pio/build/${{ matrix.environment }}/firmware.bin + path: StarMod-${{ matrix.environment }}-${{env.git_ref}}-${{env.git_hash}}.bin retention-days: 30 release: From cd40f20474a8760d8fa6602e782f7dab19f8075c Mon Sep 17 00:00:00 2001 From: Will Tatam Date: Fri, 19 Apr 2024 01:06:55 +0100 Subject: [PATCH 24/25] Artifacts in in sub directory --- .github/workflows/pio.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/pio.yml b/.github/workflows/pio.yml index fd7ddcba..1c7c030c 100644 --- a/.github/workflows/pio.yml +++ b/.github/workflows/pio.yml @@ -82,6 +82,6 @@ jobs: with: draft: True files: | - *.bin + artifact/*.bin env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} \ No newline at end of file From dad7175b158276aa4b0ad980360b0212b64a7584 Mon Sep 17 00:00:00 2001 From: Will Tatam Date: Fri, 19 Apr 2024 01:08:52 +0100 Subject: [PATCH 25/25] Artifacts in in sub directory --- .github/workflows/pio.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/pio.yml b/.github/workflows/pio.yml index 1c7c030c..f32b0628 100644 --- a/.github/workflows/pio.yml +++ b/.github/workflows/pio.yml @@ -82,6 +82,6 @@ jobs: with: draft: True files: | - artifact/*.bin + artifact/*.bin env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} \ No newline at end of file