Skip to content

[feature] leave a sticky Quality Gate comment on PRs - #4

Merged
YJack0000 merged 1 commit into
mainfrom
feature/sonar-pr-comment
Aug 23, 2026
Merged

YJack0000 merged 1 commit into
mainfrom
feature/sonar-pr-comment

Conversation

@YJack0000

Copy link
Copy Markdown
Contributor

What

Follow-up to the self-hosted Sonar migration: after every scan the workflow now leaves a sticky comment on the PR — Quality Gate verdict, failed conditions (with values vs thresholds), the open issues found on the PR, and a link to the dashboard.

  • One comment per PR, updated in place on each push (keyed by a hidden marker) — no comment spam.
  • Best-effort by design (continue-on-error + || true): a comment that could not be posted never turns a green scan red.
  • Adds an explicit permissions block (contents: read, pull-requests: write).

Native PR decoration via the community-branch-plugin (inline annotations through a GitHub App + ALM integration) can replace this later; this needs no new GitHub App to work today.

After every scan the workflow now posts (or updates in place) one PR
comment with the Quality Gate verdict, any failed conditions, the open
issues on the PR, and a link to the dashboard — so nobody has to open the
Sonar UI to learn how the gate went. Best-effort: a comment that could
not be posted never turns a green scan red.
@YJack0000
YJack0000 merged commit cce74d9 into main Aug 23, 2026
1 check passed
@github-actions

Copy link
Copy Markdown

✅ SonarQube Quality Gate passed — pathorsAI_pensieve

0 open issues on this PR.

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.

1 participant