You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
htmlreport: support remote GitHub/GitLab links for source files
Motivation:
Cppcheck-htmlreport previously generated local annotated HTML for all source files.
For private or large repositories, generating local HTML is unnecessary and cumbersome.
It consumes additional disk space, increases report generation time, and duplicates
functionality already provided by GitHub/GitLab browseable HTML pages.
This patch allows the cppcheck report itself to be public, while the actual source code
remains protected on GitHub/GitLab using their standard access controls.
Changes:
- Detect --source-dir URLs pointing to GitHub/GitLab.
- Use remote URLs in index.html instead of generating local HTML for those files.
- Line numbers link directly to GitHub/GitLab with proper anchors (#L123).
- Remote links open in a new tab (target="_blank"), preserving local HTML behavior for normal files.
0 commit comments