Skip to content

Commit cc2fb71

Browse files
committed
Report changes in memory usage that would result from merging a PR
On creation or commit to a pull request, a report of the resulting change in memory usage of the examples will be commented to the PR thread.
1 parent b7ac8f7 commit cc2fb71

File tree

2 files changed

+29
-0
lines changed

2 files changed

+29
-0
lines changed

.github/workflows/compile-examples.yml

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,9 @@ jobs:
2121
build:
2222
runs-on: ubuntu-latest
2323

24+
env:
25+
SKETCHES_REPORTS_PATH: sketches-reports
26+
2427
strategy:
2528
fail-fast: false
2629

@@ -52,3 +55,11 @@ jobs:
5255
- name: SD
5356
sketch-paths: |
5457
- examples
58+
enable-deltas-report: true
59+
sketches-report-path: ${{ env.SKETCHES_REPORTS_PATH }}
60+
61+
- name: Save memory usage change report as artifact
62+
uses: actions/upload-artifact@v2
63+
with:
64+
name: ${{ env.SKETCHES_REPORTS_PATH }}
65+
path: ${{ env.SKETCHES_REPORTS_PATH }}
Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
name: Report Size Deltas
2+
3+
on:
4+
schedule:
5+
- cron: "*/5 * * * *"
6+
# See: https://docs.github.com/en/free-pro-team@latest/actions/reference/events-that-trigger-workflows#workflow_dispatch
7+
workflow_dispatch:
8+
9+
jobs:
10+
report:
11+
runs-on: ubuntu-latest
12+
13+
steps:
14+
- name: Comment size deltas reports to PRs
15+
uses: arduino/report-size-deltas@main
16+
with:
17+
# The name of the workflow artifact created by the "Compile Examples" workflow
18+
sketches-reports-source: sketches-reports

0 commit comments

Comments
 (0)