Skip to content

Commit e7de754

Browse files
improve: Add hint about making GitHub org membership public in error messages (#772)
When users try to publish to a GitHub organization but don't have permission, the error message now includes a helpful hint suggesting they may need to make their organization membership public in GitHub settings. This addresses the issue where users couldn't understand why they were unable to publish servers from organization repositories, even when they were members of the organization. Fixes #398 Generated with [Claude Code](https://claude.ai/code) --------- Co-authored-by: claude[bot] <209825114+claude[bot]@users.noreply.github.com> Co-authored-by: adam jones <[email protected]>
1 parent 45bf43f commit e7de754

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

internal/api/handlers/v0/publish.go

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -84,5 +84,10 @@ func buildPermissionErrorMessage(attemptedResource string, permissions []auth.Pe
8484
}
8585
errorMsg += ". Attempting to publish: " + attemptedResource
8686

87+
// Add helpful hint for GitHub organization publishing issues
88+
if strings.HasPrefix(attemptedResource, "io.github.") {
89+
errorMsg += ". If you're trying to publish to a GitHub organization, you may need to make your organization membership public in your GitHub settings: https://docs.github.com/en/account-and-profile/how-tos/organization-membership/publicizing-or-hiding-organization-membership"
90+
}
91+
8792
return errorMsg
8893
}

0 commit comments

Comments
 (0)