Skip to content

build: add Clang analyzer workflow#3464

Open
shroffni wants to merge 1 commit into
linux-nvme:masterfrom
shroffni:analyzer-workflow
Open

build: add Clang analyzer workflow#3464
shroffni wants to merge 1 commit into
linux-nvme:masterfrom
shroffni:analyzer-workflow

Conversation

@shroffni

Copy link
Copy Markdown
Contributor

Add a nightly workflow job which runs the Clang static analyzer, archives the generated reports and uploads them to the artifact store and SFTP server for later inspection.

Comment thread .github/workflows/run-nightly-tests.yml Outdated
- name: Install dependencies
run: |
sudo apt update
sudo apt install -y clang-tools meson

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

We should use the pre-build ci-containers which avoids the install step which fails way to often in this environment.

I suggest we grap the 'coverity' feature and rename it to 'analize' or something like this and add all missing dependencies to it: https://github.com/linux-nvme/ci-containers/blob/main/ci-containers.yaml

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.

We should use the pre-build ci-containers which avoids the install step which fails way to often in this environment.

Yeah makes sense. Frankly, I was not aware about this ci-container repo. Anyways, first I will send a PR for this repo which would add clang-tools in the container.

I suggest we grap the 'coverity' feature and rename it to 'analize' or something like this and add all missing dependencies to it: https://github.com/linux-nvme/ci-containers/blob/main/ci-containers.yaml

Grepping coverity in the current nvme-cli code base yields the following output:
.github/workflows/coverity.yml:23: coverity-scan:
.github/workflows/coverity.yml:25: name: coverity scan
.github/workflows/coverity.yml:48: curl -o coverity_tool.tgz
.github/workflows/coverity.yml:51: https://scan.coverity.com/download/linux64
.github/workflows/coverity.yml:52: mkdir coverity-tools
.github/workflows/coverity.yml:53: tar xzf coverity_tool.tgz --strip 1 -C coverity-tools
.github/workflows/coverity.yml:61: export PATH="$PWD/coverity-tools/bin:$PATH"
.github/workflows/coverity.yml:66: tar czvf nvme-cli-coverity.tgz cov-int
.github/workflows/coverity.yml:72: --form file=@nvme-cli-coverity.tgz
.github/workflows/coverity.yml:75: https://scan.coverity.com/builds?project=linux-nvme%2Fnvme-cli
.github/workflows/coverity.yml:78: name: upload coverity artifacts
.github/workflows/coverity.yml:81: name: coverity-results
.github/workflows/coverity.yml:84: nvme-cli-coverity.tgz
README.md:12:Coverity Scan Build Status

So do you suggest instead of adding clang-analyzer support in the nightly build, I'd instead replace/rename the coverity.yml file with analyzer.yml and update it as necessary? And if yes, then it means we'd run clang-analyzer "weekly on Mondays at 00:00 UTC" and not everyday.

Please suggest.

@shroffni shroffni force-pushed the analyzer-workflow branch 4 times, most recently from 72cd621 to 5762ae7 Compare June 22, 2026 13:35
Add a nightly workflow job which runs the Clang static analyzer,
archives the generated reports and uploads them to the artifact
store and SFTP server for later inspection.

Signed-off-by: Nilay Shroff <nilay@linux.ibm.com>
@shroffni shroffni force-pushed the analyzer-workflow branch from 5762ae7 to df4597e Compare June 22, 2026 13:39
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