Skip to content

ci: add compliance script checks to example repo#101

Open
danieldegrasse wants to merge 3 commits into
zephyrproject-rtos:mainfrom
danieldegrasse:feature/compliance-script
Open

ci: add compliance script checks to example repo#101
danieldegrasse wants to merge 3 commits into
zephyrproject-rtos:mainfrom
danieldegrasse:feature/compliance-script

Conversation

@danieldegrasse

Copy link
Copy Markdown
Contributor

Add CI job to run compliance script checks within the example repo, as a demonstration of how to utilize and build on Zephyr's compliance checks.

This also enforces the compliance checks on this repo, so we need to reformat a few of the python scripts to comply with them

Add configuration files for linters used by Zephyr compliance checks.
These files are duplicated from the Zephyr repo.

Signed-off-by: Daniel DeGrasse <daniel.degrasse@analog.com>
Format example_west_command to comply with ruff CI checks

Signed-off-by: Daniel DeGrasse <daniel.degrasse@analog.com>
@danieldegrasse danieldegrasse force-pushed the feature/compliance-script branch from f750b68 to bfaded7 Compare July 3, 2026 20:10
Comment thread LICENSES/Apache-2.0.txt

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Compliance checks are failing due to extra newlines in this file, but I'm not sure if we want to strip those? I assume this license file was pulled directly from apache.org

@rettichschnidi rettichschnidi Jul 6, 2026

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.

IMHO better not to strip. Messing with the defaults of what REUSE fetches will cause extra work when doing FOSS compliance.

Also, having an example on how to create an exception would be valuable too.

Add support for running compliance checks on code contributed to the
example repository, as a demonstration for how to implement custom
compliance checks on top of those Zephyr provides

Signed-off-by: Daniel DeGrasse <daniel.degrasse@analog.com>
@danieldegrasse danieldegrasse force-pushed the feature/compliance-script branch from bfaded7 to 872fa10 Compare July 3, 2026 20:13
@danieldegrasse danieldegrasse marked this pull request as ready for review July 3, 2026 20:15
run: |
if ! command -v west &> /dev/null; then
echo "west could not be found, installing..."
python -m pip install west==1.5.0

@rettichschnidi rettichschnidi Jul 6, 2026

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.

Nit: To give a good example, this better be fixed to a cryptographically secure hash.

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