From d75685a633476433db2d715a48ffd5a046894c4f Mon Sep 17 00:00:00 2001 From: Ali Jahangiri <75624145+aliphys@users.noreply.github.com> Date: Mon, 28 Aug 2023 20:04:48 +0200 Subject: [PATCH 1/2] Make `example usage` self contained --- README.md | 92 ++++++++++++++++++++++++++++++++++++------------------- 1 file changed, 60 insertions(+), 32 deletions(-) diff --git a/README.md b/README.md index f9d2c5c..d4a190d 100644 --- a/README.md +++ b/README.md @@ -23,31 +23,33 @@ This action checks whether [Arduino](https://www.arduino.cc/) sketches compile a -- [Inputs](#inputs) - - [`cli-version`](#cli-version) - - [`fqbn`](#fqbn) - - [`platforms`](#platforms) - - [Supported platform sources:](#supported-platform-sources) - - [Boards Manager](#boards-manager) - - [Local path](#local-path) - - [Repository](#repository) - - [Archive download](#archive-download) - - [`libraries`](#libraries) - - [Supported library sources:](#supported-library-sources) - - [Library Manager](#library-manager) - - [Local path](#local-path-1) - - [Repository](#repository-1) - - [Archive download](#archive-download-1) - - [`sketch-paths`](#sketch-paths) - - [`cli-compile-flags`](#cli-compile-flags) - - [`verbose`](#verbose) - - [`sketches-report-path`](#sketches-report-path) - - [`github-token`](#github-token) - - [`enable-deltas-report`](#enable-deltas-report) - - [How it works](#how-it-works) - - [`enable-warnings-report`](#enable-warnings-report) -- [Example usage](#example-usage) -- [Additional resources](#additional-resources) +- [`arduino/compile-sketches` action](#arduinocompile-sketches-action) + - [Table of contents](#table-of-contents) + - [Inputs](#inputs) + - [`cli-version`](#cli-version) + - [`fqbn`](#fqbn) + - [`platforms`](#platforms) + - [Supported platform sources:](#supported-platform-sources) + - [Boards Manager](#boards-manager) + - [Local path](#local-path) + - [Repository](#repository) + - [Archive download](#archive-download) + - [`libraries`](#libraries) + - [Supported library sources:](#supported-library-sources) + - [Library Manager](#library-manager) + - [Local path](#local-path-1) + - [Repository](#repository-1) + - [Archive download](#archive-download-1) + - [`sketch-paths`](#sketch-paths) + - [`cli-compile-flags`](#cli-compile-flags) + - [`verbose`](#verbose) + - [`sketches-report-path`](#sketches-report-path) + - [`github-token`](#github-token) + - [`enable-deltas-report`](#enable-deltas-report) + - [How it works](#how-it-works) + - [`enable-warnings-report`](#enable-warnings-report) + - [Example usage](#example-usage) + - [Additional resources](#additional-resources) @@ -241,13 +243,39 @@ Set to `true` to cause the action to record the compiler warning count for each ## Example usage ```yaml -- uses: arduino/compile-sketches@v1 - with: - fqbn: "arduino:avr:uno" - libraries: | - - name: Servo - - name: Stepper - version: 1.1.3 +# You will see this name in the Actions tab on GitHub +name: Compile Sketches + +# Specify conditions for workflow to run +on: + push: # push to main branch + branches: + -main + + pull_request: # PR to main branch + branches: + -main + + workflow_dispatch: # Manually via button in the Actions tab + + +# This workflow involves only one job to do, called compile-sketch +jobs: + compile-sketch: + runs-on: ubuntu-latest # runner is latest Github-hosted Ubuntu + steps: # define what steps should be taken + # GA for checking out repo to runner -> https://github.com/actions/checkout + - uses: actions/checkout@v3 + # GA for compiling sketches -> https://github.com/arduino/compile-sketches + - uses: arduino/compile-sketches@v1 + with: + fqbn: "arduino:avr:uno" # specify fully qualified board name to compile sketches for + libraries: | + # load latest version of Servo library from arduino-libraries org + - name: Servo + # load version 1.1.3 of Stepper library + - name: Stepper # + version: 1.1.3 ``` ## Additional resources From ebdcbdd9fbf3ba09f0cee815d1298bf8bc193a48 Mon Sep 17 00:00:00 2001 From: Ali Jahangiri <75624145+aliphys@users.noreply.github.com> Date: Sat, 18 Nov 2023 13:19:58 +0100 Subject: [PATCH 2/2] docs: revert changes to TOC --- README.md | 52 +++++++++++++++++++++++++--------------------------- 1 file changed, 25 insertions(+), 27 deletions(-) diff --git a/README.md b/README.md index 9c7dac5..153f8c5 100644 --- a/README.md +++ b/README.md @@ -23,33 +23,31 @@ This action checks whether [Arduino](https://www.arduino.cc/) sketches compile a -- [`arduino/compile-sketches` action](#arduinocompile-sketches-action) - - [Table of contents](#table-of-contents) - - [Inputs](#inputs) - - [`cli-version`](#cli-version) - - [`fqbn`](#fqbn) - - [`platforms`](#platforms) - - [Supported platform sources:](#supported-platform-sources) - - [Boards Manager](#boards-manager) - - [Local path](#local-path) - - [Repository](#repository) - - [Archive download](#archive-download) - - [`libraries`](#libraries) - - [Supported library sources:](#supported-library-sources) - - [Library Manager](#library-manager) - - [Local path](#local-path-1) - - [Repository](#repository-1) - - [Archive download](#archive-download-1) - - [`sketch-paths`](#sketch-paths) - - [`cli-compile-flags`](#cli-compile-flags) - - [`verbose`](#verbose) - - [`sketches-report-path`](#sketches-report-path) - - [`github-token`](#github-token) - - [`enable-deltas-report`](#enable-deltas-report) - - [How it works](#how-it-works) - - [`enable-warnings-report`](#enable-warnings-report) - - [Example usage](#example-usage) - - [Additional resources](#additional-resources) +- [Inputs](#inputs) + - [`cli-version`](#cli-version) + - [`fqbn`](#fqbn) + - [`platforms`](#platforms) + - [Supported platform sources:](#supported-platform-sources) + - [Boards Manager](#boards-manager) + - [Local path](#local-path) + - [Repository](#repository) + - [Archive download](#archive-download) + - [`libraries`](#libraries) + - [Supported library sources:](#supported-library-sources) + - [Library Manager](#library-manager) + - [Local path](#local-path-1) + - [Repository](#repository-1) + - [Archive download](#archive-download-1) + - [`sketch-paths`](#sketch-paths) + - [`cli-compile-flags`](#cli-compile-flags) + - [`verbose`](#verbose) + - [`sketches-report-path`](#sketches-report-path) + - [`github-token`](#github-token) + - [`enable-deltas-report`](#enable-deltas-report) + - [How it works](#how-it-works) + - [`enable-warnings-report`](#enable-warnings-report) +- [Example usage](#example-usage) +- [Additional resources](#additional-resources)