Skip to content

chore: handle examples cmake variable - #19

Merged
gabrielfrasantos merged 2 commits into
mainfrom
feature/handle-examples-cmake-variable
Mar 29, 2026
Merged

chore: handle examples cmake variable#19
gabrielfrasantos merged 2 commits into
mainfrom
feature/handle-examples-cmake-variable

Conversation

@gabrielfrasantos

Copy link
Copy Markdown
Contributor

No description provided.

Copilot AI review requested due to automatic review settings March 29, 2026 20:44

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR updates the top-level CMake configuration to make building the examples/ subtree conditional on a CMake option, aligning behavior with the existing HALST_BUILD_EXAMPLES option.

Changes:

  • Wrap add_subdirectory(examples) with if (HALST_BUILD_EXAMPLES) ... endif() to allow disabling example targets by default.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread CMakeLists.txt Outdated
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
@gabrielfrasantos

Copy link
Copy Markdown
Contributor Author

⚠️MegaLinter analysis: Success with warnings

Descriptor Linter Files Fixed Errors Warnings Elapsed time
✅ ACTION actionlint 5 0 0 0.41s
✅ CPP clang-format 15 5 0 0 1.66s
✅ CPP cppcheck 15 0 0 1.08s
✅ DOCKERFILE hadolint 1 0 0 0.45s
✅ JSON jsonlint 7 0 0 0.17s
✅ JSON prettier 7 2 0 0 2.0s
⚠️ MARKDOWN markdownlint 6 1 10 0 1.74s
✅ MARKDOWN markdown-table-formatter 6 1 0 0 1.47s
✅ REPOSITORY git_diff yes no no 0.84s
✅ REPOSITORY grype yes no no 29.66s
✅ REPOSITORY ls-lint yes no no 0.06s
✅ REPOSITORY secretlint yes no no 41.84s
✅ REPOSITORY syft yes no no 1.26s
✅ REPOSITORY trivy yes no no 8.14s
✅ REPOSITORY trivy-sbom yes no no 1.14s
✅ REPOSITORY trufflehog yes no no 8.1s
⚠️ SPELL lychee 32 2 0 88.62s
✅ YAML prettier 8 1 0 0 1.56s
✅ YAML v8r 8 0 0 4.97s
✅ YAML yamllint 8 0 0 0.35s

Detailed Issues

⚠️ SPELL / lychee - 2 errors
[ERROR] http://mcd.rou.st.com/modules.php?name=mcu | Network error: error sending request for url (http://mcd.rou.st.com/modules.php?name=mcu) Maybe a certificate error?
[404] https://api.securityscorecards.dev/projects/github.com/embedded-pro/hal-st | Network error: Not Found
[TIMEOUT] https://st.com/ | Timeout
📝 Summary
---------------------
🔍 Total..........242
✅ Successful.....236
⏳ Timeouts.........1
🔀 Redirected.......0
👻 Excluded.........3
❓ Unknown..........0
🚫 Errors...........2

Errors in README.md
[404] https://api.securityscorecards.dev/projects/github.com/embedded-pro/hal-st | Network error: Not Found
[TIMEOUT] https://st.com/ | Timeout

Errors in .github/ISSUE_TEMPLATE/add-or-update-hal-driver.md
[ERROR] http://mcd.rou.st.com/modules.php?name=mcu | Network error: error sending request for url (http://mcd.rou.st.com/modules.php?name=mcu) Maybe a certificate error?
⚠️ MARKDOWN / markdownlint - 10 errors
.github/ISSUE_TEMPLATE/add-or-update-hal-driver.md:10 MD025/single-title/single-h1 Multiple top-level headings in the same document [Context: "How to import a HAL driver"]
CHANGELOG.md:83 MD024/no-duplicate-heading Multiple headings with the same content [Context: "⚠ BREAKING CHANGES"]
CHANGELOG.md:87 MD024/no-duplicate-heading Multiple headings with the same content [Context: "Features"]
CHANGELOG.md:94 MD024/no-duplicate-heading Multiple headings with the same content [Context: "Bug Fixes"]
CHANGELOG.md:103 MD024/no-duplicate-heading Multiple headings with the same content [Context: "Features"]
CHANGELOG.md:122 MD024/no-duplicate-heading Multiple headings with the same content [Context: "Bug Fixes"]
CHANGELOG.md:140 MD024/no-duplicate-heading Multiple headings with the same content [Context: "⚠ BREAKING CHANGES"]
CHANGELOG.md:144 MD024/no-duplicate-heading Multiple headings with the same content [Context: "Features"]
CHANGELOG.md:151 MD024/no-duplicate-heading Multiple headings with the same content [Context: "Features"]
CHANGELOG.md:162 MD024/no-duplicate-heading Multiple headings with the same content [Context: "Bug Fixes"]

See detailed reports in MegaLinter artifacts

Your project could benefit from a custom flavor, which would allow you to run only the linters you need, and thus improve runtime performances. (Skip this info by defining FLAVOR_SUGGESTIONS: false)

  • Documentation: Custom Flavors
  • Command: npx mega-linter-runner@9.0.1 --custom-flavor-setup --custom-flavor-linters ACTION_ACTIONLINT,CPP_CPPCHECK,CPP_CLANG_FORMAT,DOCKERFILE_HADOLINT,JSON_JSONLINT,JSON_PRETTIER,MARKDOWN_MARKDOWNLINT,MARKDOWN_MARKDOWN_TABLE_FORMATTER,REPOSITORY_GIT_DIFF,REPOSITORY_GRYPE,REPOSITORY_LS_LINT,REPOSITORY_SECRETLINT,REPOSITORY_SYFT,REPOSITORY_TRIVY,REPOSITORY_TRIVY_SBOM,REPOSITORY_TRUFFLEHOG,SPELL_LYCHEE,YAML_PRETTIER,YAML_YAMLLINT,YAML_V8R

MegaLinter is graciously provided by OX Security

@gabrielfrasantos
gabrielfrasantos merged commit 8167807 into main Mar 29, 2026
15 checks passed
@gabrielfrasantos
gabrielfrasantos deleted the feature/handle-examples-cmake-variable branch April 20, 2026 09:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants