Skip to content

ci: fix CodeQL workflow permissions, build conditions, and trigger scope#65

Merged
jcardozo-eth merged 2 commits intoci/codeql-advanced-setupfrom
copilot/sub-pr-62
Mar 24, 2026
Merged

ci: fix CodeQL workflow permissions, build conditions, and trigger scope#65
jcardozo-eth merged 2 commits intoci/codeql-advanced-setupfrom
copilot/sub-pr-62

Conversation

Copy link
Copy Markdown
Contributor

Copilot AI commented Mar 24, 2026

Three correctness issues in the CodeQL Advanced Setup workflow added in the previous commit.

Permissions

Added actions: read to job-level permissions — required by the actions language scanner and present in GitHub's official CodeQL starter template.

permissions:
  actions: read          # added
  contents: read
  security-events: write
  packages: read

Build configuration

  • if: matrix.language == 'java-kotlin'if: matrix.build-mode == 'manual' on both Java steps. The condition should reflect the build-mode requirement; the language-name check silently breaks if a second manually-built language is added.
  • Added cache: maven to actions/setup-java to avoid re-downloading dependencies on every run.

Trigger scope

Added explicit types: [opened, synchronize, reopened] to the pull_request trigger. Without this, GitHub fires on all 13 activity types (labeled, assigned, closed, …), causing redundant scans on non-code-change events.


💬 Send tasks to Copilot coding agent from Slack and Teams to turn conversations into code. Copilot posts an update in your thread when it's finished.

Copilot AI changed the title [WIP] ci: add CodeQL advanced setup workflow ci: fix CodeQL workflow permissions, build conditions, and trigger scope Mar 24, 2026
Copilot AI requested a review from jcardozo-eth March 24, 2026 10:28
Copy link
Copy Markdown
Member

@jcardozo-eth jcardozo-eth left a comment

Choose a reason for hiding this comment

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

LGTM — all changes are reasonable: explicit PR event types, actions: read for visibility, generic build-mode condition, and maven caching. Squash and merge.

@jcardozo-eth jcardozo-eth marked this pull request as ready for review March 24, 2026 10:33
@jcardozo-eth jcardozo-eth merged commit b5bcfe0 into ci/codeql-advanced-setup Mar 24, 2026
@jcardozo-eth jcardozo-eth deleted the copilot/sub-pr-62 branch March 24, 2026 10:34
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