From 9d27490969461c63d42bb0cf458f836276b47fde Mon Sep 17 00:00:00 2001 From: Soren Ptak Date: Thu, 24 Aug 2023 15:17:17 -0700 Subject: [PATCH 1/9] Use new version of CI-CD Actions --- .github/.cSpellWords.txt | 8 +++++ .github/workflows/ci.yml | 68 +++++++++++++++++++++++++++------------- cspell.config.yaml | 22 +++++++++++++ 3 files changed, 76 insertions(+), 22 deletions(-) create mode 100644 .github/.cSpellWords.txt create mode 100644 cspell.config.yaml diff --git a/.github/.cSpellWords.txt b/.github/.cSpellWords.txt new file mode 100644 index 0000000..158bf07 --- /dev/null +++ b/.github/.cSpellWords.txt @@ -0,0 +1,8 @@ +CMOCK +CMock +Cmock +Coverity +MISRA +Misra +coverity +misra diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 8d1f1d4..53cf6cf 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -10,7 +10,7 @@ jobs: runs-on: ubuntu-latest steps: - name: Clone This Repo - uses: actions/checkout@v2 + uses: actions/checkout@v3 - name: Build run: | sudo apt-get install -y lcov @@ -32,14 +32,14 @@ jobs: echo ${EXCLUDE[@]} | xargs lcov --rc lcov_branch_coverage=1 -r build/coverage.info -o build/coverage.info lcov --rc lcov_branch_coverage=1 --list build/coverage.info - name: Check Coverage - uses: FreeRTOS/CI-CD-Github-Actions/coverage-cop@main + uses: FreeRTOS/CI-CD-Github-Actions/coverage-cop@v2 with: - path: ./build/coverage.info + coverage-file: ./build/coverage.info build-with-default-config: runs-on: ubuntu-latest steps: - name: Clone This Repo - uses: actions/checkout@v2 + uses: actions/checkout@v3 - name: Build run: | cmake -S test -B build/ \ @@ -50,42 +50,42 @@ jobs: complexity: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v3 - name: Check complexity - uses: FreeRTOS/CI-CD-Github-Actions/complexity@main + uses: FreeRTOS/CI-CD-Github-Actions/complexity@v2 with: path: ./ doxygen: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v3 - name: Run doxygen build - uses: FreeRTOS/CI-CD-Github-Actions/doxygen@main + uses: FreeRTOS/CI-CD-Github-Actions/doxygen@v2 with: path: ./ spell-check: runs-on: ubuntu-latest steps: - name: Clone This Repo - uses: actions/checkout@v2 + uses: actions/checkout@v3 - name: Run spellings check - uses: FreeRTOS/CI-CD-Github-Actions/spellings@main + uses: FreeRTOS/CI-CD-GitHub-Actions/rust-spell-check@v2 with: path: ./ formatting: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v3 - name: Check formatting - uses: FreeRTOS/CI-CD-Github-Actions/formatting@main + uses: FreeRTOS/CI-CD-Github-Actions/formatting@v2 with: path: ./ git-secrets: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v3 - name: Checkout awslabs/git-secrets - uses: actions/checkout@v2 + uses: actions/checkout@v3 with: repository: awslabs/git-secrets ref: master @@ -99,19 +99,43 @@ jobs: memory_statistics: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v3 with: - submodules: 'recursive' + submodules: "recursive" - name: Install Python3 - uses: actions/setup-python@v2 + uses: actions/setup-python@v3 with: - python-version: '3.11.0' + python-version: "3.11.0" - name: Measure sizes - uses: FreeRTOS/CI-CD-Github-Actions/memory_statistics@main + uses: FreeRTOS/CI-CD-Github-Actions/memory_statistics@v2 with: - config: .github/memory_statistics_config.json - check_against: docs/doxygen/include/size_table.md + config: .github/memory_statistics_config.json + check_against: docs/doxygen/include/size_table.md + link-verifier: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v3 + - name: Check Links + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + uses: FreeRTOS/CI-CD-Github-Actions/link-verifier@v2 + + verify-manifest: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v3 + with: + submodules: true + fetch-depth: 0 + + - name: Run manifest verifier + uses: FreeRTOS/CI-CD-GitHub-Actions/manifest-verifier@v2 + with: + path: ./ + fail-on-incorrect-version: true + proof_ci: + if: ${{ github.event.pull_request }} runs-on: cbmc_ubuntu-latest_16-core steps: - name: Set up CBMC runner @@ -119,4 +143,4 @@ jobs: - name: Run CBMC uses: FreeRTOS/CI-CD-Github-Actions/run_cbmc@main with: - proofs_dir: test/cbmc/proofs + proofs_dir: test/cbmc/proofs \ No newline at end of file diff --git a/cspell.config.yaml b/cspell.config.yaml new file mode 100644 index 0000000..e7d8a56 --- /dev/null +++ b/cspell.config.yaml @@ -0,0 +1,22 @@ +--- +$schema: https://raw.githubusercontent.com/streetsidesoftware/cspell/main/cspell.schema.json +version: '0.2' +# Allows things like stringLength +allowCompoundWords: true +useGitignore: true +# Could split this up? And do a dictionary for each repo? +# But feel like if this isn't super slow +# That having just one single dictionary might be nicer? +dictionaryDefinitions: + - name: freertos-words + path: '.github/.cSpellWords.txt' + addWords: true +dictionaries: + - freertos-words +ignorePaths: + - 'node_modules' + - '.cSpellWords.txt' + - 'dependency' + - 'docs' + - 'ThirdParty' + From 007063720f3ccd1ba59d932cc7d2a4e847583db8 Mon Sep 17 00:00:00 2001 From: Soren Ptak Date: Fri, 25 Aug 2023 11:19:56 -0700 Subject: [PATCH 2/9] Use cSpell spell check, and use ubuntu-20.04 for formatting check --- .github/.cSpellWords.txt | 15 +++ .github/workflows/ci.yml | 4 +- lexicon.txt | 100 ------------------ test/cbmc/proofs/Defender_GetTopic/README.md | 2 +- .../cbmc/proofs/Defender_MatchTopic/README.md | 2 +- 5 files changed, 19 insertions(+), 104 deletions(-) delete mode 100644 lexicon.txt diff --git a/.github/.cSpellWords.txt b/.github/.cSpellWords.txt index 158bf07..6d8e1f3 100644 --- a/.github/.cSpellWords.txt +++ b/.github/.cSpellWords.txt @@ -1,8 +1,23 @@ +CBMC +CBOR CMOCK CMock Cmock Coverity +DDISABLE +DNDEBUG +DUNITY MISRA +MQTT Misra +Wunused +cbmc +cbor +cmet +cmock coverity +ctest +lcov misra +sinclude +utest diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 53cf6cf..aa8f13e 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -69,11 +69,11 @@ jobs: - name: Clone This Repo uses: actions/checkout@v3 - name: Run spellings check - uses: FreeRTOS/CI-CD-GitHub-Actions/rust-spell-check@v2 + uses: FreeRTOS/CI-CD-GitHub-Actions/spellings@v2 with: path: ./ formatting: - runs-on: ubuntu-latest + runs-on: ubuntu-20.04 steps: - uses: actions/checkout@v3 - name: Check formatting diff --git a/lexicon.txt b/lexicon.txt deleted file mode 100644 index af0febd..0000000 --- a/lexicon.txt +++ /dev/null @@ -1,100 +0,0 @@ -addr -api -apis -aws -bi -bo -br -bufferlength -cbor -colspan -com -cond -config -configpagestyle -const -copydoc -css -defenderapi -defenderbadparameter -defenderbuffertoosmall -defendercborreportaccepted -defendercborreportpublish -defendercborreportrejected -defendererror -defenderinvalidtopic -defenderjsonreportaccepted -defenderjsonreportpublish -defenderjsonreportrejected -defendernomatch -defenderstatus -defendersuccess -defendertopic -defgroup -developerguide -doesn -doxygen -endcode -endcond -endif -enum -gcc -getdeviceserialnumber -gettopic -github -hed -html -https -inc -ingroup -iot -iso -json -logdebug -logerror -loginfo -logwarn -mainpage -matchapi -matchtopic -md -mdash -memcpy -misra -mit -mqtt -noninfringement -ns -os -param -pbuffer -png -po -posix -poutapi -poutlength -poutthingnamelength -ppoutthingname -pre -premainingtopic -pthingname -ptopic -remainingtopiclength -remediate -rm -sdk -spdx -strlen -sublicense -tcp -td -thingname -thingnamelength -toolchain -topicbuffer -topiclength -tr -udp -uint -utest -xa diff --git a/test/cbmc/proofs/Defender_GetTopic/README.md b/test/cbmc/proofs/Defender_GetTopic/README.md index 56f00c2..f4c13ea 100644 --- a/test/cbmc/proofs/Defender_GetTopic/README.md +++ b/test/cbmc/proofs/Defender_GetTopic/README.md @@ -11,7 +11,7 @@ To run the proof. * Run "make". * Open html/index.html in a web browser. -To use [`arpa`](https://github.com/awslabs/aws-proof-build-assistant) to simplify writing Makefiles. +To use [`arpa`](https://awslabs.github.io/aws-proof-build-assistant) to simplify writing Makefiles. ------------- * Run "make arpa" to generate a Makefile.arpa that contains relevant build information for the proof. diff --git a/test/cbmc/proofs/Defender_MatchTopic/README.md b/test/cbmc/proofs/Defender_MatchTopic/README.md index c095d85..08fbf79 100644 --- a/test/cbmc/proofs/Defender_MatchTopic/README.md +++ b/test/cbmc/proofs/Defender_MatchTopic/README.md @@ -11,7 +11,7 @@ To run the proof. * Run "make". * Open html/index.html in a web browser. -To use [`arpa`](https://github.com/awslabs/aws-proof-build-assistant) to simplify writing Makefiles. +To use [`arpa`](https://awslabs.github.io/aws-proof-build-assistant) to simplify writing Makefiles. ------------- * Run "make arpa" to generate a Makefile.arpa that contains relevant build information for the proof. From 360548b3b943b4829802058243287f1f70428414 Mon Sep 17 00:00:00 2001 From: Soren Ptak Date: Wed, 30 Aug 2023 15:29:06 -0700 Subject: [PATCH 3/9] Use the new version of the cspell.config.yaml --- cspell.config.yaml | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/cspell.config.yaml b/cspell.config.yaml index e7d8a56..331f137 100644 --- a/cspell.config.yaml +++ b/cspell.config.yaml @@ -4,6 +4,12 @@ version: '0.2' # Allows things like stringLength allowCompoundWords: true useGitignore: true +languageSettings: + - allowCompoundWords: true + caseSensitive: false + enabled: true + languageId: c + locale: "*" # Could split this up? And do a dictionary for each repo? # But feel like if this isn't super slow # That having just one single dictionary might be nicer? @@ -14,9 +20,8 @@ dictionaryDefinitions: dictionaries: - freertos-words ignorePaths: - - 'node_modules' - '.cSpellWords.txt' - 'dependency' - 'docs' - 'ThirdParty' - + - 'History.txt' From e889810734746d0ff877a1d76136d024863344f1 Mon Sep 17 00:00:00 2001 From: Soren Ptak Date: Thu, 31 Aug 2023 14:19:22 -0700 Subject: [PATCH 4/9] Update the cspell config file to clean it up a bit --- cspell.config.yaml | 16 ++++++++++------ 1 file changed, 10 insertions(+), 6 deletions(-) diff --git a/cspell.config.yaml b/cspell.config.yaml index 331f137..911ce1d 100644 --- a/cspell.config.yaml +++ b/cspell.config.yaml @@ -3,24 +3,28 @@ $schema: https://raw.githubusercontent.com/streetsidesoftware/cspell/main/cspell version: '0.2' # Allows things like stringLength allowCompoundWords: true + +# Read files not to spell check from the git ignore useGitignore: true + +# Language settings for C languageSettings: - - allowCompoundWords: true - caseSensitive: false + - caseSensitive: false enabled: true languageId: c locale: "*" -# Could split this up? And do a dictionary for each repo? -# But feel like if this isn't super slow -# That having just one single dictionary might be nicer? + +# Add a dictionary, and the path to the word list dictionaryDefinitions: - name: freertos-words path: '.github/.cSpellWords.txt' addWords: true + dictionaries: - freertos-words + +# Paths and files to ignore ignorePaths: - - '.cSpellWords.txt' - 'dependency' - 'docs' - 'ThirdParty' From ad3628def9b412ca6a450536443a35df3529bda8 Mon Sep 17 00:00:00 2001 From: Soren Ptak Date: Fri, 1 Sep 2023 09:31:48 -0700 Subject: [PATCH 5/9] Use merged version of some actions --- .github/workflows/ci.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index aa8f13e..a6bc5ff 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -32,7 +32,7 @@ jobs: echo ${EXCLUDE[@]} | xargs lcov --rc lcov_branch_coverage=1 -r build/coverage.info -o build/coverage.info lcov --rc lcov_branch_coverage=1 --list build/coverage.info - name: Check Coverage - uses: FreeRTOS/CI-CD-Github-Actions/coverage-cop@v2 + uses: FreeRTOS/CI-CD-Github-Actions/coverage-cop@main with: coverage-file: ./build/coverage.info build-with-default-config: @@ -52,7 +52,7 @@ jobs: steps: - uses: actions/checkout@v3 - name: Check complexity - uses: FreeRTOS/CI-CD-Github-Actions/complexity@v2 + uses: FreeRTOS/CI-CD-Github-Actions/complexity@main with: path: ./ doxygen: @@ -129,7 +129,7 @@ jobs: fetch-depth: 0 - name: Run manifest verifier - uses: FreeRTOS/CI-CD-GitHub-Actions/manifest-verifier@v2 + uses: FreeRTOS/CI-CD-GitHub-Actions/manifest-verifier@main with: path: ./ fail-on-incorrect-version: true From eff933e91b8542a607206e38833e3b4c01b9472f Mon Sep 17 00:00:00 2001 From: Soren Ptak Date: Fri, 1 Sep 2023 18:22:11 -0700 Subject: [PATCH 6/9] Use merged mainline version of formatting --- .github/workflows/ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index a6bc5ff..6257eae 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -77,7 +77,7 @@ jobs: steps: - uses: actions/checkout@v3 - name: Check formatting - uses: FreeRTOS/CI-CD-Github-Actions/formatting@v2 + uses: FreeRTOS/CI-CD-Github-Actions/formatting@main with: path: ./ git-secrets: From 707bffd72ba7bb0dafd75366d372037f9616acc2 Mon Sep 17 00:00:00 2001 From: Soren Ptak Date: Sat, 2 Sep 2023 16:09:32 -0700 Subject: [PATCH 7/9] Update the README file --- README.md | 111 ++++++++++++++++++++++++++++++++++-------------------- 1 file changed, 71 insertions(+), 40 deletions(-) diff --git a/README.md b/README.md index 395901d..a90dcb8 100644 --- a/README.md +++ b/README.md @@ -1,32 +1,50 @@ # AWS IoT Device Defender Library -The Device Defender library enables you to send device metrics to the [AWS IoT Device Defender Service](https://aws.amazon.com/iot-device-defender/). -This library also supports custom metrics, a feature that helps you monitor operational health metrics that are unique to your fleet or use case. For example, you can define a new metric to monitor the memory usage or CPU usage on your devices. -This library has no dependencies on any additional libraries other than the -standard C library, and therefore, can be used with any MQTT client library. -This library is distributed under the [MIT Open Source License](LICENSE). +**[API Documentation Pages for current and previous releases of this library can be found here](https://aws.github.io/Device-Defender-for-AWS-IoT-embedded-sdk/)** + +The Device Defender library enables you to send device metrics to the +[AWS IoT Device Defender Service](https://aws.amazon.com/iot-device-defender/). +This library also supports custom metrics, a feature that helps you monitor +operational health metrics that are unique to your fleet or use case. For +example, you can define a new metric to monitor the memory usage or CPU usage on +your devices. This library has no dependencies on any additional libraries other +than the standard C library, and therefore, can be used with any MQTT client +library. This library is distributed under the +[MIT Open Source License](LICENSE). This library has gone through code quality checks including verification that no -function has a [GNU Complexity](https://www.gnu.org/software/complexity/manual/complexity.html) +function has a +[GNU Complexity](https://www.gnu.org/software/complexity/manual/complexity.html) score over 8, and checks against deviations from mandatory rules in the -[MISRA coding standard](https://www.misra.org.uk). -Deviations from the MISRA C:2012 guidelines are documented under [MISRA Deviations](MISRA.md). -This library has also undergone static code analysis using [Coverity static analysis](https://scan.coverity.com/), -and validation of memory safety through the [CBMC automated reasoning tool](https://www.cprover.org/cbmc/). - -See memory requirements for this library [here](./docs/doxygen/include/size_table.md). - -**AWS IoT Device Defender v1.3.0 [source code](https://github.com/aws/Device-Defender-for-AWS-IoT-embedded-sdk/tree/v1.3.0/source) is part of the [FreeRTOS 202210.00 LTS](https://github.com/FreeRTOS/FreeRTOS-LTS/tree/202210.00-LTS) release.** - -**AWS IoT Device Defender v1.1.0 [source code](https://github.com/aws/Device-Defender-for-AWS-IoT-embedded-sdk/tree/v1.1.0/source) is part of the [FreeRTOS 202012.01 LTS](https://github.com/FreeRTOS/FreeRTOS-LTS/tree/202012.01-LTS) release.** +[MISRA coding standard](https://www.misra.org.uk). Deviations from the MISRA +C:2012 guidelines are documented under [MISRA Deviations](MISRA.md). This +library has also undergone static code analysis using +[Coverity static analysis](https://scan.coverity.com/), and validation of memory +safety through the +[CBMC automated reasoning tool](https://www.cprover.org/cbmc/). + +See memory requirements for this library +[here](./docs/doxygen/include/size_table.md). + +**AWS IoT Device Defender v1.3.0 +[source code](https://github.com/aws/Device-Defender-for-AWS-IoT-embedded-sdk/tree/v1.3.0/source) +is part of the +[FreeRTOS 202210.00 LTS](https://github.com/FreeRTOS/FreeRTOS-LTS/tree/202210.00-LTS) +release.** + +**AWS IoT Device Defender v1.1.0 +[source code](https://github.com/aws/Device-Defender-for-AWS-IoT-embedded-sdk/tree/v1.1.0/source) +is part of the +[FreeRTOS 202012.01 LTS](https://github.com/FreeRTOS/FreeRTOS-LTS/tree/202012.01-LTS) +release.** ## AWS IoT Device Defender Client Config File The AWS IoT Device Defender Client Library exposes build configuration macros that are required for building the library. A list of all the configurations and their default values are defined in -[defender_config_defaults.h](source/include/defender_config_defaults.h). -To provide custom values for the configuration macros, a config file named +[defender_config_defaults.h](source/include/defender_config_defaults.h). To +provide custom values for the configuration macros, a config file named `defender_config.h` can be provided by the application to the library. By default, a `defender_config.h` config file is required to build the library. @@ -35,13 +53,14 @@ values, provide `DEFENDER_DO_NOT_USE_CUSTOM_CONFIG` as a compile time preprocessor macro. **Thus, the Device Defender client library can be built by either**: -* Defining a `defender_config.h` file in the application, and adding it to the -include directories list of the library. + +- Defining a `defender_config.h` file in the application, and adding it to the + include directories list of the library. **OR** -* Defining the `DEFENDER_DO_NOT_USE_CUSTOM_CONFIG` preprocessor macro for the -library build. +- Defining the `DEFENDER_DO_NOT_USE_CUSTOM_CONFIG` preprocessor macro for the + library build. ## Building the Library @@ -49,9 +68,9 @@ The [defenderFilePaths.cmake](defenderFilePaths.cmake) file contains the information of all source files and the header include paths required to build the Device Defender client library. -As mentioned in the previous section, either a custom config file -(i.e. `defender_config.h`) or `DEFENDER_DO_NOT_USE_CUSTOM_CONFIG` macro needs to -be provided to build the Device Defender client library. +As mentioned in the previous section, either a custom config file (i.e. +`defender_config.h`) or `DEFENDER_DO_NOT_USE_CUSTOM_CONFIG` macro needs to be +provided to build the Device Defender client library. For a CMake example of building the Device Defender client library with the `defenderFilePaths.cmake` file, refer to the `coverity_analysis` library target @@ -62,16 +81,19 @@ in [test/CMakeLists.txt](test/CMakeLists.txt) file. ### Platform Prerequisites - For running unit tests: - - **C90 compiler** like gcc. - - **CMake 3.13.0 or later**. - - **Ruby 2.0.0 or later** is additionally required for the CMock test framework (that we use). -- For running the coverage target, **gcov** and **lcov** are additionally required. + - **C90 compiler** like gcc. + - **CMake 3.13.0 or later**. + - **Ruby 2.0.0 or later** is additionally required for the CMock test + framework (that we use). +- For running the coverage target, **gcov** and **lcov** are additionally + required. ### Steps to build **Unit Tests** 1. Go to the root directory of this repository. -1. Run the *cmake* command: `cmake -S test -B build -DBUILD_CLONE_SUBMODULES=ON`. +1. Run the _cmake_ command: + `cmake -S test -B build -DBUILD_CLONE_SUBMODULES=ON`. 1. Run this command to build the library and unit tests: `make -C build all`. @@ -81,34 +103,42 @@ in [test/CMakeLists.txt](test/CMakeLists.txt) file. ## CBMC -To learn more about CBMC and proofs specifically, review the training material [here](https://model-checking.github.io/cbmc-training). +To learn more about CBMC and proofs specifically, review the training material +[here](https://model-checking.github.io/cbmc-training). The `test/cbmc/proofs` directory contains CBMC proofs. -In order to run these proofs you will need to install CBMC and other tools by following the instructions [here](https://model-checking.github.io/cbmc-training/installation.html). +In order to run these proofs you will need to install CBMC and other tools by +following the instructions +[here](https://model-checking.github.io/cbmc-training/installation.html). ## Reference examples The AWS IoT Embedded C-SDK repository contains a demo showing the use of AWS IoT -Device Defender Client Library [here](https://github.com/aws/aws-iot-device-sdk-embedded-C/tree/main/demos/defender/defender_demo_json) +Device Defender Client Library +[here](https://github.com/aws/aws-iot-device-sdk-embedded-C/tree/main/demos/defender/defender_demo_json) on a POSIX platform. ## Documentation ### Existing documentation -For pre-generated documentation, please see the documentation linked in the locations below: -| Location | -| :-: | -| [AWS IoT Device SDK for Embedded C](https://github.com/aws/aws-iot-device-sdk-embedded-C#releases-and-documentation) | +For pre-generated documentation, please see the documentation linked in the +locations below: + +| Location | +| :-------------------------------------------------------------------------------------------------------------------------------------: | +| [AWS IoT Device SDK for Embedded C](https://github.com/aws/aws-iot-device-sdk-embedded-C#releases-and-documentation) | | [FreeRTOS.org](https://freertos.org/Documentation/api-ref/device-defender-for-aws-iot-embedded-sdk/docs/doxygen/output/html/index.html) | -Note that the latest included version of the AWS IoT Device Defender library may differ across repositories. +Note that the latest included version of the AWS IoT Device Defender library may +differ across repositories. ### Generating documentation The Doxygen references were created using Doxygen version 1.9.2. To generate the -Doxygen pages, please run the following command from the root of this repository: +Doxygen pages, please run the following command from the root of this +repository: ```shell doxygen docs/doxygen/config.doxyfile @@ -116,4 +146,5 @@ doxygen docs/doxygen/config.doxyfile ## Contributing -See [CONTRIBUTING.md](./.github/CONTRIBUTING.md) for information on contributing. +See [CONTRIBUTING.md](./.github/CONTRIBUTING.md) for information on +contributing. From d584ecc848dfe8a77c069a973c03e2e010aeedf8 Mon Sep 17 00:00:00 2001 From: Soren Ptak Date: Tue, 5 Sep 2023 10:26:26 -0700 Subject: [PATCH 8/9] Add in bot formatting action --- .github/workflows/formatting.yml | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) create mode 100644 .github/workflows/formatting.yml diff --git a/.github/workflows/formatting.yml b/.github/workflows/formatting.yml new file mode 100644 index 0000000..f7141e7 --- /dev/null +++ b/.github/workflows/formatting.yml @@ -0,0 +1,23 @@ +name: Format Pull Request Files + +on: + issue_comment: + types: [created] + +env: + bashPass: \033[32;1mPASSED - + bashInfo: \033[33;1mINFO - + bashFail: \033[31;1mFAILED - + bashEnd: \033[0m + +jobs: + Formatting: + name: Run Formatting Check + if: ${{ github.event.issue.pull_request }} && + ( ( github.event.comment.body == '/bot run uncrustify' ) || + ( github.event.comment.body == '/bot run formatting' ) ) + runs-on: ubuntu-20.04 + steps: + - name: Apply Formatting Fix + uses: FreeRTOS/CI-CD-Github-Actions/formatting-bot@v2 + id: check-formatting From cda28fe63d89d7c5b6dd72c85515a777f2bd3ac9 Mon Sep 17 00:00:00 2001 From: Soren Ptak Date: Tue, 5 Sep 2023 13:55:41 -0700 Subject: [PATCH 9/9] Update to use merged mainline actions, use checkout@v3 instead of checkout@v2 on all jobs --- .github/workflows/ci.yml | 8 ++++---- .github/workflows/formatting.yml | 2 +- .github/workflows/release.yml | 4 ++-- 3 files changed, 7 insertions(+), 7 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 6257eae..47f3c71 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -60,7 +60,7 @@ jobs: steps: - uses: actions/checkout@v3 - name: Run doxygen build - uses: FreeRTOS/CI-CD-Github-Actions/doxygen@v2 + uses: FreeRTOS/CI-CD-Github-Actions/doxygen@main with: path: ./ spell-check: @@ -69,7 +69,7 @@ jobs: - name: Clone This Repo uses: actions/checkout@v3 - name: Run spellings check - uses: FreeRTOS/CI-CD-GitHub-Actions/spellings@v2 + uses: FreeRTOS/CI-CD-Github-Actions/spellings@main with: path: ./ formatting: @@ -107,7 +107,7 @@ jobs: with: python-version: "3.11.0" - name: Measure sizes - uses: FreeRTOS/CI-CD-Github-Actions/memory_statistics@v2 + uses: FreeRTOS/CI-CD-Github-Actions/memory_statistics@main with: config: .github/memory_statistics_config.json check_against: docs/doxygen/include/size_table.md @@ -118,7 +118,7 @@ jobs: - name: Check Links env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - uses: FreeRTOS/CI-CD-Github-Actions/link-verifier@v2 + uses: FreeRTOS/CI-CD-Github-Actions/link-verifier@main verify-manifest: runs-on: ubuntu-latest diff --git a/.github/workflows/formatting.yml b/.github/workflows/formatting.yml index f7141e7..8257add 100644 --- a/.github/workflows/formatting.yml +++ b/.github/workflows/formatting.yml @@ -19,5 +19,5 @@ jobs: runs-on: ubuntu-20.04 steps: - name: Apply Formatting Fix - uses: FreeRTOS/CI-CD-Github-Actions/formatting-bot@v2 + uses: FreeRTOS/CI-CD-Github-Actions/formatting-bot@main id: check-formatting diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index d5024d7..0589bad 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -16,7 +16,7 @@ jobs: runs-on: ubuntu-latest steps: - name: Checkout code - uses: actions/checkout@v2 + uses: actions/checkout@v3 with: ref: ${{ github.event.inputs.commit_id }} - name: Configure git identity @@ -53,7 +53,7 @@ jobs: - name: Install ZIP tools run: sudo apt-get install zip unzip - name: Checkout code - uses: actions/checkout@v2 + uses: actions/checkout@v3 with: ref: ${{ github.event.inputs.commit_id }} path: Device-Defender-for-AWS-IoT-embedded-sdk