craft your forge, build your project, grow your community freely
1<!--
2SPDX-FileCopyrightText: 2025 Romain Maneschi <romain@gitroot.dev>
3 4SPDX-License-Identifier: CC-BY-SA-4.0
5--> 6 7# Managing users
8 9The `.gitroot/users.yml` yaml file is the most important file for any GitRoot repository. It describe who can write where.
1011## Structure
1213```yaml
14owner:
15branches:
16 - name: main
17users:
18 - pseudo: GitRoot
19avatar: ""20emails:
21 - GitRoot@localhost
22ssh:
23 - ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIMHNFk8uaXGbf8gWegbfJj2l/mht7c02qUjouHzjwsrA
24```2526## Group
2728The first important thing is the `group name`, here it is `owner`. Only this group is requiered, it is the group where users (or GitRoot itself or plugins) can write in the default branch.
2930For others groups you can use the name you want like.
3132## Branch
3334Inside a group there are the branches their are able to push to. Here all users of the `owner` group are able to push to master.
3536You can add as many branch as you want.
3738You can also use the name `*` to say all branches.
3940## Users
4142Then comes users. A user in GitRoot is only an ssh public key. But for convenience I have added pseudo, emails and avatar (not used today). A user can have as amny emails and ssh key as he wants.
4344## Special cases
4546With only this structure you can model the workflow you want for your repository. For example you can [ban users](../how-tos/ban_user.md), allow [all users on all branches](../how-tos/contributors_can_write_all.md) or [accept contributions only for know users](../how-tos/no_anonymous_user.md).
4748I'm pretty sure you will find other ways to manage your project with that structure. If it the case, please, complete the [documentation](../index.md).