diff --git a/.github/workflows/flash_analysis.yml b/.github/workflows/flash_analysis.yml
index d7a2d5b171..2b52095118 100644
--- a/.github/workflows/flash_analysis.yml
+++ b/.github/workflows/flash_analysis.yml
@@ -10,8 +10,8 @@ on:
jobs:
analyze_flash:
- name: FLASH usage analysis
- runs-on: ubuntu-latest
+ name: Analyzing ${{ matrix.target }}
+ runs-on: [runs-on,runner=8cpu-linux-x64,image=ubuntu24-full-x64,"run-id=${{ github.run_id }}",spot=false]
container:
image: px4io/px4-dev-nuttx-focal
strategy:
@@ -29,7 +29,7 @@ jobs:
- name: Git ownership workaround
run: git config --system --add safe.directory '*'
- - name: Build
+ - name: Build Target
run: make ${{ matrix.target }}
- name: Store the ELF with the change
@@ -73,36 +73,46 @@ jobs:
echo "$EOF" >> $GITHUB_OUTPUT
post_pr_comment:
- name: Post PR comment
- runs-on: ubuntu-latest
+ name: Publish Results
+ runs-on: [runs-on,runner=1cpu-linux-x64,image=ubuntu24-full-x64,"run-id=${{ github.run_id }}",spot=false]
needs: [analyze_flash]
+ if: ${{ github.event.pull_request }}
steps:
- - name: If it's a PR add a comment with the bloaty output
- if: ${{ github.event.pull_request }}
- uses: actions/github-script@v6
+ - name: Find Comment
+ uses: peter-evans/find-comment@v3
+ id: fc
with:
- script: |
- const comment = [
- '## FLASH Analysis',
- '',
- 'px4_fmu-v5x
',
- '',
- '```',
- `${{ needs.analyze_flash.outputs.px4_fmu-v5x }}`,
- '```',
- ' ',
- '',
- '',
- 'px4_fmu-v6x
',
- '',
- '```',
- `${{ needs.analyze_flash.outputs.px4_fmu-v6x }}`,
- '```',
- ' '
- ]
- github.rest.issues.createComment({
- issue_number: context.issue.number,
- owner: context.repo.owner,
- repo: context.repo.repo,
- body: comment.join('\n')
- })
+ issue-number: ${{ github.event.pull_request.number }}
+ comment-author: 'github-actions[bot]'
+ body-includes: FLASH Analysis
+
+ - name: Set Build Time
+ id: bt
+ run: |
+ echo "timestamp=$(date +'%Y-%m-%dT%H:%M:%S')" >> $GITHUB_OUTPUT
+
+ - name: Create or update comment
+ uses: peter-evans/create-or-update-comment@v4
+ with:
+ comment-id: ${{ steps.fc.outputs.comment-id }}
+ issue-number: ${{ github.event.pull_request.number }}
+ body: |
+ ## FLASH Analysis
+
+ px4_fmu-v5x
+
+ ```
+ ${{ needs.analyze_flash.outputs.px4_fmu-v5x }}
+ ```
+
+
+
+ px4_fmu-v6x
+
+ ```
+ ${{ needs.analyze_flash.outputs.px4_fmu-v6x }}
+ ```
+
+
+ **Updated: _${{ steps.bt.outputs.timestamp }}_**
+ edit-mode: replace