Expand description
Per-repository decisions the hosting clients honour without every caller passing a repository: which token a repository’s host calls use (a token command, for a GitHub App bot) and whether assignment is blocked.
The hosting crate cannot read the repository’s stored settings (those live
in crates that depend on it), so a higher crate installs one
RepoScopes for the process. A client then asks it, per call, by the
(integration id, project) pair every call already carries: no call site
needs a repository handed to it, and a surface that forgets to register a
repository simply gets the plain behaviour (personal token, assignment
allowed) rather than a failure.
Constants§
- ASSIGNMENT_
BLOCKED - The reason shown wherever an assignment is refused or an assignee field is hidden. Also the marker a CLI answer is recognised by (exit code 2).
Traits§
- Repo
Scopes - What a repository’s stored settings say about its host calls.
Functions§
- acts_
as_ bot - Whether the repository’s host calls are made by an App bot.
- assignment_
blocked - Whether assignment is blocked for
projectofintegration_id. - install
- Installs the process’s scopes (the first call wins).
- is_
app_ installation_ token - Whether
tokenis a GitHub App installation token (ghs_): it has no “me” and cannot callGET /user. - learn_
login - Persists
loginas who the token posts as inproject. - learned_
login - The login learned from our first post in
project, if any. - post_as
- The configured “Post as” name of
project, if any.