You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The three share a payload shape but differ by scope. Worth deciding whether they live under one set of *-GitHubRuleset cmdlets parameterized by scope, or per-scope cmdlets (*-GitHubRepositoryRuleset, *-GitHubOrganizationRuleset, *-GitHubEnterpriseRuleset).
Auth note: enterprise rulesets require enterprise-admin authorization. GitHub Apps generally cannot manage enterprise rulesets, so a PAT with admin:enterprise is needed there — the cmdlet should accept whichever -Context token is supplied and error clearly when the scope is insufficient.
Note this is distinct from Get-GitHubRepositoryRuleSuite (rule evaluation results) — this issue is about managing ruleset definitions.
Activity
[-][Feature] Repositories - Rules - Manage rulesets for repositories[/-][+]Add repository ruleset management functions[/+]MariusStorhaug commentedon Jul 25, 2026
Flagging a sibling scope for this area, driven by
MSXOrg/Custo(PR #1), which maintains rulesets centrally as an enterprise control:…/repos/{owner}/{repo}/rulesets(this issue).…/orgs/{org}/rulesets.…/enterprises/{enterprise}/rulesets.The three share a payload shape but differ by scope. Worth deciding whether they live under one set of
*-GitHubRulesetcmdlets parameterized by scope, or per-scope cmdlets (*-GitHubRepositoryRuleset,*-GitHubOrganizationRuleset,*-GitHubEnterpriseRuleset).Auth note: enterprise rulesets require enterprise-admin authorization. GitHub Apps generally cannot manage enterprise rulesets, so a PAT with
admin:enterpriseis needed there — the cmdlet should accept whichever-Contexttoken is supplied and error clearly when the scope is insufficient.Note this is distinct from
Get-GitHubRepositoryRuleSuite(rule evaluation results) — this issue is about managing ruleset definitions.