Skip to content

ci: add permission comments and remove redundant comments from workflows#1985

Merged
hrzlgnm merged 4 commits intomainfrom
fix/workflows
Mar 8, 2026
Merged

ci: add permission comments and remove redundant comments from workflows#1985
hrzlgnm merged 4 commits intomainfrom
fix/workflows

Conversation

@hrzlgnm
Copy link
Copy Markdown
Owner

@hrzlgnm hrzlgnm commented Mar 8, 2026

Summary

  • Add contents: read permission with comment to winget-reusable.yml (has release trigger)
  • Remove redundant "No special permissions needed" comments from reusable workflows
  • Permissions are set by caller for reusable workflows (as per AGENTS.md)

Summary by CodeRabbit

  • Chores
    • Updated CI/CD workflow configurations to adjust declared job permissions and clarify intent with inline comments.
    • Removed or tightened some workflow permission declarations and added a few read-only permissions to reduce scope.
    • Cosmetic formatting and comment improvements across workflow files to improve maintainability and auditability.

@hrzlgnm
Copy link
Copy Markdown
Owner Author

hrzlgnm commented Mar 8, 2026

@coderabbitai review

@coderabbitai
Copy link
Copy Markdown
Contributor

coderabbitai bot commented Mar 8, 2026

✅ Actions performed

Review triggered.

Note: CodeRabbit is an incremental review system and does not re-review already reviewed commits. This command is applicable only when automatic reviews are paused.

@github-actions github-actions bot added the bug Something isn't working label Mar 8, 2026
@coderabbitai
Copy link
Copy Markdown
Contributor

coderabbitai bot commented Mar 8, 2026

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

Run ID: 717a2cf3-f660-4706-a34e-81f78933989d

📥 Commits

Reviewing files that changed from the base of the PR and between d20dd2a and e31cd82.

📒 Files selected for processing (4)
  • .github/workflows/aur-reusable.yml
  • .github/workflows/ci.yml
  • .github/workflows/release.yml
  • .github/workflows/winget-reusable.yml
🚧 Files skipped from review as they are similar to previous changes (2)
  • .github/workflows/winget-reusable.yml
  • .github/workflows/ci.yml

📝 Walkthrough

Walkthrough

Reorganized GitHub Actions permissions across reusable and CI workflows: several top-level permission blocks were removed, one publish job gained contents: read, and some permission entries were reformatted with explanatory comments. No runtime logic or job steps were changed. (41 words)

Changes

Cohort / File(s) Summary
Permissions Removed
.github/workflows/asset-checksums-reusable.yml, .github/workflows/publish-sbom-reusable.yml, .github/workflows/source-checksums-reusable.yml
Removed top-level permissions blocks that previously granted contents: write and/or other explicit permissions. No other workflow steps modified.
Permissions Adjusted
.github/workflows/aur-reusable.yml
Removed a per-job packages: read permission in update-aur job; retained release-info job permission with an inline comment.
Permission Added
.github/workflows/winget-reusable.yml
Added a permissions block to the publish job granting contents: read with an inline comment.
Formatting & Comments
.github/workflows/ci.yml, .github/workflows/release.yml
Reflowed permission declarations to multi-line entries and added inline explanatory comments; no permission key/value changes.

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~20 minutes

Possibly related PRs

Suggested labels

chore

Poem

Oh boy, they trimmed the scopes and left a note,
Comments whisper why the keys were wrote.
Permissions pruned, the workflows stay the same—
Neat little fences around each tiny flame. 🔐✨

🚥 Pre-merge checks | ✅ 2
✅ Passed checks (2 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title accurately summarizes the main changes: adding permission comments to workflows and removing redundant comments from reusable workflows, with secondary adjustments to permissions themselves.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch fix/workflows

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

Copy link
Copy Markdown
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 1

🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Inline comments:
In @.github/workflows/aur-reusable.yml:
- Around line 34-36: The workflow's update-aur job unnecessarily requests
packages: read permission; remove the packages: read entry from the update-aur
job's permissions block (and any accompanying comment claiming it's "to read
release info from GitHub Packages") because that job consumes outputs from the
previous job and only performs curl checksum fetches and AUR publishing; update
the comment (or delete it) to reflect the true rationale or omit it entirely to
avoid misleading documentation.

ℹ️ Review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

Run ID: 6026ff90-7efb-45c3-a2a1-9cf1763464fb

📥 Commits

Reviewing files that changed from the base of the PR and between 85b235d and d20dd2a.

📒 Files selected for processing (7)
  • .github/workflows/asset-checksums-reusable.yml
  • .github/workflows/aur-reusable.yml
  • .github/workflows/ci.yml
  • .github/workflows/publish-sbom-reusable.yml
  • .github/workflows/release.yml
  • .github/workflows/source-checksums-reusable.yml
  • .github/workflows/winget-reusable.yml
💤 Files with no reviewable changes (3)
  • .github/workflows/source-checksums-reusable.yml
  • .github/workflows/asset-checksums-reusable.yml
  • .github/workflows/publish-sbom-reusable.yml

@hrzlgnm
Copy link
Copy Markdown
Owner Author

hrzlgnm commented Mar 8, 2026

@coderabbitai review

@coderabbitai
Copy link
Copy Markdown
Contributor

coderabbitai bot commented Mar 8, 2026

✅ Actions performed

Review triggered.

Note: CodeRabbit is an incremental review system and does not re-review already reviewed commits. This command is applicable only when automatic reviews are paused.

@hrzlgnm
Copy link
Copy Markdown
Owner Author

hrzlgnm commented Mar 8, 2026

@coderabbitai review

@coderabbitai
Copy link
Copy Markdown
Contributor

coderabbitai bot commented Mar 8, 2026

✅ Actions performed

Review triggered.

Note: CodeRabbit is an incremental review system and does not re-review already reviewed commits. This command is applicable only when automatic reviews are paused.

@hrzlgnm hrzlgnm enabled auto-merge (squash) March 8, 2026 12:40
@hrzlgnm hrzlgnm merged commit 2ea9647 into main Mar 8, 2026
38 of 43 checks passed
@hrzlgnm hrzlgnm deleted the fix/workflows branch March 8, 2026 12:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant