Skip to content

Comments

Add doc-sync slash command workflow#28

Merged
activadee merged 1 commit intomainfrom
chore/doc-sync-workflow
Nov 9, 2025
Merged

Add doc-sync slash command workflow#28
activadee merged 1 commit intomainfrom
chore/doc-sync-workflow

Conversation

@activadee
Copy link
Owner

  • adds a reusable workflow that listens for '/docs' comments on PRs
  • runs codex doc sync only when the repository owner triggers it
  • pushes the auto-generated documentation updates via the shared workflow

if: >-
github.event.issue.pull_request &&
startsWith(github.event.comment.body, '/docs') &&
github.actor == github.repository_owner
Copy link
Contributor

Choose a reason for hiding this comment

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

github.actor == github.repository_owner only evaluates true when the commenter’s username exactly matches the repository owner string. That works for a personal fork but fails for any org-owned repo, since github.repository_owner becomes the organization (e.g. my-org) and no individual github.actor login will ever match. As written, no one— including org owners—can trigger this job, so /docs commands never run. Please use a more appropriate guard, e.g. check github.event.comment.author_association for OWNER/MEMBER or maintain a list of allowed usernames.

@github-actions
Copy link
Contributor

github-actions bot commented Nov 9, 2025

Codex Review Summary

Recommendation: 🚫 Changes required – 1 inline issue detected.

Summary:
Doc sync workflow never fires for org-owned repos because the actor comparison can’t succeed, so the feature doesn’t work for most collaborators.

Inline findings:

  • .github/workflows/doc-sync.yml:12github.actor == github.repository_owner only evaluates true when the commenter’s username exactly matches the repository owner string. That works for a personal fork but fails for any org-owned repo, since github.repository_owner becomes the organization (e.g. my-org) and no individual github.actor login will ever match. As written, no one— including org owners—can trigger this job, so /docs commands never run. Please use a more appropriate guard, e.g. check github.event.comment.author_association for OWNER/MEMBER or maintain a list of allowed usernames.

Generated at 2025-11-09T20:19:03.322Z.

@activadee activadee merged commit ffcea00 into main Nov 9, 2025
2 checks passed
@activadee activadee deleted the chore/doc-sync-workflow branch November 9, 2025 20:21
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