> 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/id/konfigurasi/overleaf-toolkit/sinkronisasi-github.md).

# Sinkronisasi GitHub

{% hint style="info" %}
Fitur ini dikembangkan oleh [ayaka-notes/overleaf-pro](https://github.com/ayaka-notes/overleaf-pro), dimodifikasi oleh [yu-i-i/overleaf-cep](https://github.com/yu-i-i/overleaf-cep). Fitur ini diperkenalkan sejak v6.2.0 dan versi yang lebih baru. Statusnya masih beta. Kami membutuhkan masukan Anda jika Anda mengalami masalah apa pun.
{% endhint %}

{% columns %}
{% column %}

<figure><img src="/files/d2b58937bc52961d86821713a1ccf922d9cd3f1e" alt=""><figcaption></figcaption></figure>

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

{% column %}

<figure><img src="/files/9bb4faf7fd6e73d2c154a5494559849a0986724c" alt=""><figcaption></figcaption></figure>

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

### Siapkan Sinkronisasi GitHub

{% hint style="warning" %}
Anda perlu mengaktifkan [git-bridge](/on-premises/id/konfigurasi/overleaf-toolkit/git-integration.md) terlebih dahulu sebelum menggunakan Sinkronisasi GitHub.

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

```dotenv
GIT_BRIDGE_ENABLED=true
```

{% endcode %}
{% endhint %}

Kunjungi [pengaturan pengembang](https://github.com/settings/developers) untuk membuat aplikasi OAuth GitHub Anda, lalu salin `CLIENT_ID` dan `SECRET`.&#x20;

**Catatan**: URL callback OAuth Anda adalah: `${OVERLEAF_SITE_URL}/user/github-sync/oauth2/callback`.

Kemudian, tambahkan pengaturan berikut ke file variabel lingkungan Overleaf Anda.

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

```dotenv
# digunakan untuk mengenkripsi token akses GitHub pengguna.
# Cara membuat: `openssl rand -hex 32`
GITHUB_TOKEN_CIPHER_PASSWORD=0123456789ABCDEFG # ganti dengan milik Anda

# Pengaturan Sinkronisasi GitHub
GITHUB_SYNC_ENABLED=true
GITHUB_SYNC_CLIENT_ID=
GITHUB_SYNC_CLIENT_SECRET=

# Callback OAuth adalah: ${OVERLEAF_SITE_URL}/user/github-sync/oauth2/callback
# (Opsional) GITHUB_SYNC_PROXY_URL=http://10.0.0.1:10808
```

{% endcode %}

{% hint style="warning" %}
Sebelum mengonfigurasi URL callback OAuth GitHub, pastikan `OVERLEAF_SITE_URL` sudah diatur dengan benar.
{% endhint %}

Jika Anda berada di Tiongkok daratan, Anda mungkin perlu mengonfigurasi proxy untuk mengakses GitHub. Atur variabel lingkungan berikut: `GITHUB_SYNC_PROXY_URL=http://10.0.0.1:10808`.

{% hint style="warning" %}
Jangan gunakan `127.0.0.1` untuk host proxy. Jika proxy berjalan di server host, gunakan IP LAN server (seperti `192.168.1.xx`) dan pastikan proxy dikonfigurasi untuk menerima koneksi dari perangkat di jaringan lokal.
{% 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/id/konfigurasi/overleaf-toolkit/sinkronisasi-github.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.
