collaborators section grants individual users access to repositories with specific permissions. This is useful for giving access to external contributors or individuals who are not part of a team.
Basic Configuration
The GitHub username of the collaborator. Usernames are automatically converted to lowercase to avoid comparison issues.
The permission to grant the collaborator. Can be one of:
pull- Can pull, but not push to or administer this repositorypush- Can pull and push, but not administer this repositoryadmin- Can pull, push and administer this repository
Include/Exclude Patterns
You can useinclude and exclude lists to control which repositories a collaborator has access to. This is particularly useful for organization-level settings.
List of repository names where this collaborator should have access. When specified, the collaborator will only have access to these repositories.
List of repository names where this collaborator should not have access. The collaborator will have access to all other repositories in the organization.
Pending Invitations
Safe Settings handles both active collaborators and pending invitations:- Active collaborators: Users who have accepted their invitation
- Pending invitations: Users who have been invited but haven’t accepted yet
Complete Examples
Basic Collaborator Access
Organization-Level with Include
Organization-Level with Exclude
Mixed Patterns
How Include/Exclude Works
- Include: When specified, creates an allowlist. The collaborator will only have access to repositories in the include list.
- Exclude: When specified, creates a denylist. The collaborator will have access to all repositories except those in the exclude list.
- Neither: When neither is specified, the collaborator configuration applies to the current repository (repo-level settings) or all repositories (org-level settings).
- Both: You should not specify both
includeandexcludefor the same collaborator.
Collaborators vs Teams
Use collaborators when:- Granting access to external contributors
- Giving access to individuals not in your organization
- Providing temporary or limited access
- Managing access for groups of organization members
- Applying consistent permissions across multiple people
- Organizing people by project or responsibility