Enable issue comment invocation for clang-tidy-check workflow#342
Merged
Enable issue comment invocation for clang-tidy-check workflow#342
Conversation
Contributor
There was a problem hiding this comment.
Pull request overview
Adds an on-demand invocation path for the existing clang-tidy check workflow so developers can trigger it from PR comments (in addition to the existing pull_request and workflow_dispatch triggers).
Changes:
- Add
issue_commenttrigger with an authorization gate and command parsing for@…bot tidy-check - Use the
get-pr-infoaction to resolve PR checkout info (ref/repo/base SHA) when triggered by comments - Extend the comment-posting job to work for both
pull_requestandissue_commentevents and add a summarized results comment
This commit enhances the clang-tidy-check workflow to support on-demand invocation via issue comments using '@phlexbot tidy-check', providing developers with a convenient way to run clang-tidy checks without waiting for automatic PR triggers. Changes: - Add issue_comment trigger with authorization check restricting access to OWNER, COLLABORATOR, and MEMBER roles following established security patterns from clang-tidy-fix workflow - Integrate get-pr-info action in pre-check job to extract PR details (ref, repo, base SHA, PR number) from issue comment events - Update permissions to include pull-requests: write for posting comments on PRs - Enhance clang-tidy-pr-comments job to support both pull_request and issue_comment event types with proper PR number resolution - Add summary comment when triggered via issue comment that includes: - Total count of issues found - Breakdown of issues by check type sorted by frequency - Reference to inline comments for details - Suggestion to use '@phlexbot tidy-fix' for auto-fixing The workflow now supports three invocation methods: 1. Automatic execution on pull requests 2. Manual execution via workflow_dispatch 3. On-demand execution via '@phlexbot tidy-check' comment on PRs This provides developers with flexibility to run clang-tidy checks on-demand while maintaining existing automatic PR checking behavior.
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
6e84140 to
2a523f9
Compare
knoepfel
approved these changes
Feb 23, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This commit enhances the clang-tidy-check workflow to support on-demand
invocation via issue comments using '@phlexbot tidy-check', providing
developers with a convenient way to run clang-tidy checks without
waiting for automatic PR triggers.
Changes:
Add issue_comment trigger with authorization check restricting access
to OWNER, COLLABORATOR, and MEMBER roles following established
security patterns from clang-tidy-fix workflow
Integrate get-pr-info action in pre-check job to extract PR details
(ref, repo, base SHA, PR number) from issue comment events
Update permissions to include pull-requests: write for posting
comments on PRs
Enhance clang-tidy-pr-comments job to support both pull_request and
issue_comment event types with proper PR number resolution
Add summary comment when triggered via issue comment that includes:
The workflow now supports three invocation methods:
This provides developers with flexibility to run clang-tidy checks
on-demand while maintaining existing automatic PR checking behavior.