# Use Gitserver with partial replicas

> Learn how to manage partial replicas when working with GitHub and Unity Version Control.

Unity Version Control (UVCS) supports partial replicas, which don’t map to GitHub. Avoid or work around issues in mixed GitHub and UVCS scenarios.

## Partial replicas aren’t visible to GitHub

Ensure that GitHub mappings only calculate when the correct branches are in the UVCS repository.

When GitServer indexes new changesets, it creates GitHub mappings. GitServer ignores any pushes that can alter the SHA of a changeset and potentially break synchronization with GitHub repositories that have already pulled a changeset.

For example, the following screenshot shows that you can push changeset 10, even if changeset 9 on branch `001` hasn't been pushed. GitServer recalculates the GitHub mappings without including branch `001`. If you later push the branch `001`, GitHub will ignore it because it's not part of the GitHub mappings:


**A side by side screenshot of the visual branch explorer in UVCS compared with the branch explorer for the central repository (GitServer). The screenshot has annotated text that repeats the information in the previous paragraph. :**
![A side by side screenshot of the visual branch explorer in UVCS compared with the branch explorer for the central repository (GitServer). The screenshot has annotated text that repeats the information in the previous paragraph. ](/api/media?file=/unity-version-control/media/images/gitserver/partial-replica-restrictions.png)

## Unlinked branches aren’t visible to GitHub

Because GitHub doesn’t allow partial replicas, any branches that don’t have a parent branch that links them to the `main` branch aren’t visible to GitHub:


**A side by side screenshot of the visual branch explorer in UVCS compared with the branch explorer for the central repository (GitServer). The screenshot shows that a branch not directly linked to main is ignored by GitServer.:**
![A side by side screenshot of the visual branch explorer in UVCS compared with the branch explorer for the central repository (GitServer). The screenshot shows that a branch not directly linked to main is ignored by GitServer.](/api/media?file=/unity-version-control/media/images/gitserver/partial-replica-unliked-branches.png)

Similarly, any merges to `main` from unlinked branches are ignored.

### Force map unlinked branches

To make a branch available to GitHub even if it doesn’t have a parent branch or the changesets don’t meet the required conditions, add `add branch.toForceMap` entries in your `gitserver.conf` file as follows:

```conf
# branches which changesets are made visible
# although they have unlinked merge sources
branch.toForceMap=/main
```

## Xlinks with Gitserver

Gitserver ignores changesets with unresolved Xlinks so they aren’t visible to GitHub clients. For example, if you have a branch `main@root` that contains an Xlink to `main@xlink`, but in changeset `15` on the root branch, the Xlink points at a changeset that isn’t replicated yet:


**A screenshot of the visual branch explorer that shows that changeset \`15\` is xlinked to a changeset that isn't replicatied or linked to the main branch.:**
![A screenshot of the visual branch explorer that shows that changeset 15 is xlinked to a changeset that isn't replicatied or linked to the main branch.](/api/media?file=/unity-version-control/media/images/gitserver/xlink-ignored-container-branch.png)

This means that GitServer ignores changeset `15` until the changeset you replicate the changeset it Xlinks to.

### Force GitServer to ignore missing xlinks

To configure GitServer to skip missing Xlinks and allow synchronization with GitHub even if you lose some content, add `unresolvedxlink.skip=true` to your `gitserver.conf` file as follows:

```conf
# skip the xlink entries that cannot be resolved
unresolvedxlink.skip=true
```
