> For the complete documentation index, see [llms.txt](https://overleaf-pro.ayaka.space/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://overleaf-pro.ayaka.space/on-premises/de/konfiguration/overleaf-toolkit/github-synchronisierung.md).

# GitHub-Synchronisierung

{% hint style="info" %}
Diese Funktion wurde entwickelt von [ayaka-notes/overleaf-pro](https://github.com/ayaka-notes/overleaf-pro), geändert von [yu-i-i/overleaf-cep](https://github.com/yu-i-i/overleaf-cep). Es wurde ab v6.2.0 und höher eingeführt. Es befindet sich immer noch im Beta-Status. Wir benötigen Ihr Feedback, falls Sie Probleme haben.
{% endhint %}

{% columns %}
{% column %}

<figure><img src="/files/39ed06a33fe7ef1c90d14375437a023c172b281b" alt=""><figcaption></figcaption></figure>

<figure><img src="/files/e353dea8cdd9c9ce64499aa4a081324bcd34191b" alt=""><figcaption></figcaption></figure>
{% endcolumn %}

{% column %}

<figure><img src="/files/90f8245bbe3969344275baf9a2e230b5ce3c9e18" alt=""><figcaption></figcaption></figure>

<figure><img src="/files/ca73136d55485f82ceb306652e4860373ef1acf7" alt=""><figcaption></figcaption></figure>
{% endcolumn %}
{% endcolumns %}

### GitHub-Synchronisierung einrichten

{% hint style="warning" %}
Sie müssen zuerst [git-bridge](/on-premises/de/konfiguration/overleaf-toolkit/git-integration.md) aktivieren, bevor Sie die GitHub-Synchronisierung verwenden.

{% code title="config/overleaf.rc" %}

```dotenv
GIT_BRIDGE_ENABLED=true
```

{% endcode %}
{% endhint %}

Besuchen Sie [Entwicklereinstellungen](https://github.com/settings/developers) um Ihre GitHub-OAuth-Anwendung zu erstellen, und kopieren Sie Ihre `CLIENT_ID` und `SECRET`.&#x20;

**Hinweise**: Ihre OAuth-Callback-URL ist: `${OVERLEAF_SITE_URL}/user/github-sync/oauth2/callback`.

Fügen Sie dann die folgenden Einstellungen zu Ihren Overleaf-Umgebungsvariablendateien hinzu.

{% code title="config/variables.env" overflow="wrap" %}

```dotenv
# wird verwendet, um das GitHub-Zugriffstoken des Benutzers zu verschlüsseln.
# So generieren Sie es: `openssl rand -hex 32`
GITHUB_TOKEN_CIPHER_PASSWORD=0123456789ABCDEFG # auf Ihren Wert geändert

# GitHub-Synchronisierungs-Einstellungen
GITHUB_SYNC_ENABLED=true
GITHUB_SYNC_CLIENT_ID=
GITHUB_SYNC_CLIENT_SECRET=

# Die OAuth-Callback-URL ist: ${OVERLEAF_SITE_URL}/user/github-sync/oauth2/callback
# (Optional) GITHUB_SYNC_PROXY_URL=http://10.0.0.1:10808
```

{% endcode %}

{% hint style="warning" %}
Bevor Sie die GitHub-OAuth-Callback-URL konfigurieren, stellen Sie sicher, `OVERLEAF_SITE_URL` ist korrekt festgelegt.
{% endhint %}

Wenn Sie sich auf dem chinesischen Festland befinden, müssen Sie möglicherweise einen Proxy konfigurieren, um auf GitHub zuzugreifen. Legen Sie die folgende Umgebungsvariable fest: `GITHUB_SYNC_PROXY_URL=http://10.0.0.1:10808`.

{% hint style="warning" %}
Verwenden Sie nicht `127.0.0.1` für den Proxy-Host. Wenn der Proxy auf dem Host-Server läuft, verwenden Sie die LAN-IP des Servers (z. B. `192.168.1.xx`) Adresse und stellen Sie sicher, dass der Proxy so konfiguriert ist, dass er Verbindungen von Geräten im lokalen Netzwerk akzeptiert.
{% endhint %}


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://overleaf-pro.ayaka.space/on-premises/de/konfiguration/overleaf-toolkit/github-synchronisierung.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
