diff --git a/.codespellrc b/.codespellrc new file mode 100644 index 0000000..1629857 --- /dev/null +++ b/.codespellrc @@ -0,0 +1,7 @@ +# See: https://github.com/codespell-project/codespell#using-a-config-file +[codespell] +# In the event of a false positive, add the problematic word, in all lowercase, to a comma-separated list here: +ignore-words-list = , +check-filenames = +check-hidden = +skip = ./.git,./extras/TrustAnchors,./src/bearssl diff --git a/.github/workflows/compile-examples.yml b/.github/workflows/compile-examples.yml index ad2cf32..c66e6d5 100644 --- a/.github/workflows/compile-examples.yml +++ b/.github/workflows/compile-examples.yml @@ -1,5 +1,6 @@ name: Compile Examples +# See: https://docs.github.com/en/free-pro-team@latest/actions/reference/events-that-trigger-workflows on: pull_request: paths: @@ -11,6 +12,11 @@ on: - .github/workflows/compile-examples.yml - examples/** - src/** + schedule: + # Run every Tuesday at 8 AM UTC to catch breakage caused by changes to external resources (libraries, platforms). + - cron: "0 8 * * TUE" + workflow_dispatch: + repository_dispatch: jobs: build: @@ -23,7 +29,10 @@ jobs: - source-path: ./ - name: ArduinoECCX08 # sketch paths to compile (recursive) for all boards - UNIVERSAL_SKETCH_PATHS: '"examples/SHA1" "examples/SHA256"' + UNIVERSAL_SKETCH_PATHS: | + - examples/SHA1 + - examples/SHA256 + SKETCHES_REPORTS_PATH: sketches-reports strategy: fail-fast: false @@ -44,33 +53,38 @@ jobs: type: wifi101 libraries: | - name: WiFi101 - sketch-paths: '"examples/WiFiSSLClient"' + sketch-paths: | + - examples/WiFiSSLClient # GSM boards - board: type: gsm libraries: | - name: MKRGSM - sketch-paths: '"examples/MKRGSMSSLClient"' + sketch-paths: | + - examples/MKRGSMSSLClient steps: - name: Checkout uses: actions/checkout@v2 - name: Compile examples - uses: per1234/actions/libraries/compile-examples@beaac5ae4bb7ab294f1305e436172fde4c281fc8 + uses: arduino/compile-sketches@main with: + github-token: ${{ secrets.GITHUB_TOKEN }} fqbn: ${{ matrix.board.fqbn }} libraries: | ${{ env.UNIVERSAL_LIBRARIES }} ${{ matrix.libraries }} - sketch-paths: ${{ env.UNIVERSAL_SKETCH_PATHS }} ${{ matrix.sketch-paths }} - size-report-sketch: SHA256 - enable-size-deltas-report: true + sketch-paths: | + ${{ env.UNIVERSAL_SKETCH_PATHS }} + ${{ matrix.sketch-paths }} verbose: true + enable-deltas-report: true + sketches-report-path: ${{ env.SKETCHES_REPORTS_PATH }} - name: Save sketches report as artifact if: github.event_name == 'pull_request' uses: actions/upload-artifact@v2 with: - name: size-deltas-reports - path: size-deltas-reports + path: ${{ env.SKETCHES_REPORTS_PATH }} + name: ${{ env.SKETCHES_REPORTS_PATH }} diff --git a/.github/workflows/report-size-deltas.yml b/.github/workflows/report-size-deltas.yml index fb75d80..944d92c 100644 --- a/.github/workflows/report-size-deltas.yml +++ b/.github/workflows/report-size-deltas.yml @@ -1,9 +1,17 @@ name: Report Size Deltas +# See: https://docs.github.com/en/free-pro-team@latest/actions/reference/events-that-trigger-workflows on: + push: + paths: + - ".github/workflows/report-size-deltas.yml" schedule: - # schedule action for every five minutes (ends up being a little longer in practice) + # Run at the minimum interval allowed by GitHub Actions. + # Note: GitHub Actions periodically has outages which result in workflow failures. + # In this event, the workflows will start passing again once the service recovers. - cron: "*/5 * * * *" + workflow_dispatch: + repository_dispatch: jobs: report: @@ -11,4 +19,7 @@ jobs: steps: - name: Comment size deltas reports to PRs - uses: arduino/actions/libraries/report-size-deltas@master + uses: arduino/report-size-deltas@main + with: + # The name of the workflow artifact created by the sketch compilation workflow + sketches-reports-source: sketches-reports diff --git a/.github/workflows/spell-check.yml b/.github/workflows/spell-check.yml index fba93da..01bee87 100644 --- a/.github/workflows/spell-check.yml +++ b/.github/workflows/spell-check.yml @@ -1,17 +1,22 @@ name: Spell Check -on: [push, pull_request] +# See: https://docs.github.com/en/free-pro-team@latest/actions/reference/events-that-trigger-workflows +on: + push: + pull_request: + schedule: + # Run every Tuesday at 8 AM UTC to catch new misspelling detections resulting from dictionary updates. + - cron: "0 8 * * TUE" + workflow_dispatch: + repository_dispatch: jobs: spellcheck: runs-on: ubuntu-latest steps: - - name: Checkout + - name: Checkout repository uses: actions/checkout@v2 - name: Spell check - uses: arduino/actions/libraries/spell-check@master - with: - ignore-words-list: extras/codespell-ignore-words-list.txt - skip-paths: ./extras/TrustAnchors,./src/bearssl + uses: codespell-project/actions-codespell@master diff --git a/extras/codespell-ignore-words-list.txt b/extras/codespell-ignore-words-list.txt deleted file mode 100644 index e69de29..0000000